-- Hello to anyone reading this, and thank you for checking out my Blackjack AddOn!
-- For any questions or queries, you're welcome to add my Battle Tag: Hyrav#2336

playerName = UnitName("player");
currentRealm = GetRealmName()

version = "v5.0.2"
turn = 0
gameRunning = false
tableLocked = false
tableSpectator = false

player1Active = false
player1PPSideBetWin = false
player1213SideBetWin = false
player1DoubleToggle = false
player1SplitToggle = false
player1DoubleHand1Toggle = false
player1DoubleHand2Toggle = false
player1SessionWinCalled = false
player1totalBetAmount = 0
player1totalWin = 0
player1totalLoss = 0
player1totalProfit = 0
player1TotalBankrollAmount = 0
player1NumberOfCards = 0
player1NumberOfCardsH1 = 0
player1NumberOfCardsH2 = 0
player1SessionWin = 0
player1Hotstreak = 0

player2Active = false
player2PPSideBetWin = false
player2213SideBetWin = false
player2DoubleToggle = false
player2SplitToggle = false
player2DoubleHand1Toggle = false
player2DoubleHand2Toggle = false
player2SessionWinCalled = false
player2totalBetAmount = 0
player2totalWin = 0
player2totalLoss = 0
player2totalProfit = 0
player2TotalBankrollAmount = 0
player2NumberOfCards = 0
player2NumberOfCardsH1 = 0
player2NumberOfCardsH2 = 0
player2SessionWin = 0
player2Hotstreak = 0

player3Active = false
player3PPSideBetWin = false
player3213SideBetWin = false
player3DoubleToggle = false
player3SplitToggle = false
player3DoubleHand1Toggle = false
player3DoubleHand2Toggle = false
player3SessionWinCalled = false
player3totalBetAmount = 0
player3totalWin = 0
player3totalLoss = 0
player3totalProfit = 0
player3TotalBankrollAmount = 0
player3NumberOfCards = 0
player3NumberOfCardsH1 = 0
player3NumberOfCardsH2 = 0
player3SessionWin = 0
player3Hotstreak = 0

player4Active = false
player4PPSideBetWin = false
player4213SideBetWin = false
player4DoubleToggle = false
player4SplitToggle = false
player4DoubleHand1Toggle = false
player4DoubleHand2Toggle = false
player4SessionWinCalled = false
player4totalBetAmount = 0
player4totalWin = 0
player4totalLoss = 0
player4totalProfit = 0
player4TotalBankrollAmount = 0
player4NumberOfCards = 0
player4NumberOfCardsH1 = 0
player4NumberOfCardsH2 = 0
player4SessionWin = 0
player4Hotstreak = 0

player5Active = false
player5PPSideBetWin = false
player5213SideBetWin = false
player5DoubleToggle = false
player5SplitToggle = false
player5DoubleHand1Toggle = false
player5DoubleHand2Toggle = false
player5SessionWinCalled = false
player5totalBetAmount = 0
player5totalWin = 0
player5totalLoss = 0
player5totalProfit = 0
player5TotalBankrollAmount = 0
player5NumberOfCards = 0
player5NumberOfCardsH1 = 0
player5NumberOfCardsH2 = 0
player5SessionWin = 0
player5Hotstreak = 0

termsAgreed = false

countdownDuration = 30

fadeDuration = 6
fadeIntervals = 4
fadeIntervalDuration = fadeDuration / fadeIntervals

mixedPairPayoutValue = 5
mixedPairPayoutReturn = mixedPairPayoutValue + 1
colouredPairPayoutValue = 10
colouredPairPayoutReturn = colouredPairPayoutValue + 1
perfectPairPayoutValue = 25
perfectPairPayoutReturn = perfectPairPayoutValue + 1
flushPayoutValue = 5
flushPayoutReturn = flushPayoutValue + 1
straightPayoutValue = 10
straightPayoutReturn = straightPayoutValue + 1
threeOfAKindPayoutValue = 25
threeOfAKindPayoutReturn = threeOfAKindPayoutValue + 1
straightFlushPayoutValue = 40
straightFlushPayoutReturn = straightFlushPayoutValue + 1
suitedThreeOfAKindPayoutValue = 100
suitedThreeOfAKindPayoutReturn = suitedThreeOfAKindPayoutValue + 1

minBetMain = 1000
maxBetMain = 25000
minBetPP = 100
maxBetPP = 2500
minBet213 = 100
maxBet213 = 2500

drawnCards = {}
dealtCards = {}
playerBankingInfo = {}
seatFrameFadeInfo = {}

seatFadeInfo = {
    mode = "OUT",
    timeToFade = 6,
    finishedFunc = function() seatFrame:Hide() end
}

soundFiles = {
    "1", "2", "3", "4", "5", "6", "7", "8", "9", "10",
    "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21",
    "1 or 11", "2 or 12", "3 or 13", "4 or 14", "5 or 15", "6 or 16", -- 22, 23, 24, 25, 26, 27
    "7 or 17", "8 or 18", "9 or 19", "10 or 20", -- 28, 29, 30, 31

    "DealingCard", "ConfirmBet", -- 32, 33
    "Hit", "Stand", "Double", "Split", -- 34, 35, 36, 37

    "Player1Blackjack", "Player1Win", "Player1Push", "Player1Loss", "Player1Bust", -- 38, 39, 40, 41, 42
    "Player1SplitWinWin", "Player1SplitWinPush", "Player1SplitWinLoss", -- 43, 44, 45
    "Player1SplitPushWin", "Player1SplitPushPush", "Player1SplitPushLoss", -- 46, 47, 48
    "Player1SplitLossWin", "Player1SplitLossPush", "Player1SplitLossLoss", -- 49, 50, 51

    "Player2Blackjack", "Player2Win", "Player2Push", "Player2Loss", "Player2Bust", -- 52, 53, 54, 55, 56
    "Player2SplitWinWin", "Player2SplitWinPush", "Player2SplitWinLoss", -- 57, 58, 59
    "Player2SplitPushWin", "Player2SplitPushPush", "Player2SplitPushLoss", -- 60, 61, 62
    "Player2SplitLossWin", "Player2SplitLossPush", "Player2SplitLossLoss", -- 63, 64, 65
    
    "Player3Blackjack", "Player3Win", "Player3Push", "Player3Loss", "Player3Bust", -- 66, 67, 68, 69, 70
    "Player3SplitWinWin", "Player3SplitWinPush", "Player3SplitWinLoss", -- 71, 72, 73
    "Player3SplitPushWin", "Player3SplitPushPush", "Player3SplitPushLoss", -- 74, 75, 76
    "Player3SplitLossWin", "Player3SplitLossPush", "Player3SplitLossLoss", -- 77, 78, 79

    "Player4Blackjack", "Player4Win", "Player4Push", "Player4Loss", "Player4Bust", -- 80, 81, 82, 83, 84
    "Player4SplitWinWin", "Player4SplitWinPush", "Player4SplitWinLoss", -- 85, 86, 87
    "Player4SplitPushWin", "Player4SplitPushPush", "Player4SplitPushLoss", -- 88, 89, 90
    "Player4SplitLossWin", "Player4SplitLossPush", "Player4SplitLossLoss", -- 91, 92, 93

    "Player5Blackjack", "Player5Win", "Player5Push", "Player5Loss", "Player5Bust", -- 94, 95, 96, 97, 98
    "Player5SplitWinWin", "Player5SplitWinPush", "Player5SplitWinLoss", -- 99, 100, 101
    "Player5SplitPushWin", "Player5SplitPushPush", "Player5SplitPushLoss", -- 102, 103, 104
    "Player5SplitLossWin", "Player5SplitLossPush", "Player5SplitLossLoss", -- 105, 106, 107

    "AllPlayersWin", "AllPlayersPush", "AllPlayersLoss", -- 108, 109, 110

    "DealerBlackjack", "DealerBust", -- 111, 112

    "Female_ComeBackAnytime", "Female_PaymentPlan", "Female_PleasureDoingBusiness", -- 113, 114, 115
    "Male_AhPotentialCustomer", "Male_HaveAGoodOne", "Male_TimeIsMoney" -- 116, 117, 118

}

soundFilePaths = {}

for i, fileName in ipairs(soundFiles) do
    soundFilePaths[i] = "Interface\\AddOns\\Blackjack_Retail\\Sounds\\" .. fileName .. ".mp3"
end

cardNames = {
    ["AD.tga"] = "Ace of Diamonds",
    ["2D.tga"] = "2 of Diamonds",
    ["3D.tga"] = "3 of Diamonds",
    ["4D.tga"] = "4 of Diamonds",
    ["5D.tga"] = "5 of Diamonds",
    ["6D.tga"] = "6 of Diamonds",
    ["7D.tga"] = "7 of Diamonds",
    ["8D.tga"] = "8 of Diamonds",
    ["9D.tga"] = "9 of Diamonds",
    ["10D.tga"] = "10 of Diamonds",
    ["JD.tga"] = "Jack of Diamonds",
    ["QD.tga"] = "Queen of Diamonds",
    ["KD.tga"] = "King of Diamonds",
    ["AH.tga"] = "Ace of Hearts",
    ["2H.tga"] = "2 of Hearts",
    ["3H.tga"] = "3 of Hearts",
    ["4H.tga"] = "4 of Hearts",
    ["5H.tga"] = "5 of Hearts",
    ["6H.tga"] = "6 of Hearts",
    ["7H.tga"] = "7 of Hearts",
    ["8H.tga"] = "8 of Hearts",
    ["9H.tga"] = "9 of Hearts",
    ["10H.tga"] = "10 of Hearts",
    ["JH.tga"] = "Jack of Hearts",
    ["QH.tga"] = "Queen of Hearts",
    ["KH.tga"] = "King of Hearts",
    ["AC.tga"] = "Ace of Clubs",
    ["2C.tga"] = "2 of Clubs",
    ["3C.tga"] = "3 of Clubs",
    ["4C.tga"] = "4 of Clubs",
    ["5C.tga"] = "5 of Clubs",
    ["6C.tga"] = "6 of Clubs",
    ["7C.tga"] = "7 of Clubs",
    ["8C.tga"] = "8 of Clubs",
    ["9C.tga"] = "9 of Clubs",
    ["10C.tga"] = "10 of Clubs",
    ["JC.tga"] = "Jack of Clubs",
    ["QC.tga"] = "Queen of Clubs",
    ["KC.tga"] = "King of Clubs",
    ["AS.tga"] = "Ace of Spades",
    ["2S.tga"] = "2 of Spades",
    ["3S.tga"] = "3 of Spades",
    ["4S.tga"] = "4 of Spades",
    ["5S.tga"] = "5 of Spades",
    ["6S.tga"] = "6 of Spades",
    ["7S.tga"] = "7 of Spades",
    ["8S.tga"] = "8 of Spades",
    ["9S.tga"] = "9 of Spades",
    ["10S.tga"] = "10 of Spades",
    ["JS.tga"] = "Jack of Spades",
    ["QS.tga"] = "Queen of Spades",
    ["KS.tga"] = "King of Spades",
    -- Add more card entries as needed
}

cardValues = {
    ["AD.tga"] = {1, 11},
    ["2D.tga"] = {2},
    ["3D.tga"] = {3},
    ["4D.tga"] = {4},
    ["5D.tga"] = {5},
    ["6D.tga"] = {6},
    ["7D.tga"] = {7},
    ["8D.tga"] = {8},
    ["9D.tga"] = {9},
    ["10D.tga"] = {10},
    ["JD.tga"] = {10},
    ["QD.tga"] = {10},
    ["KD.tga"] = {10},
    ["AH.tga"] = {1, 11},
    ["2H.tga"] = {2},
    ["3H.tga"] = {3},
    ["4H.tga"] = {4},
    ["5H.tga"] = {5},
    ["6H.tga"] = {6},
    ["7H.tga"] = {7},
    ["8H.tga"] = {8},
    ["9H.tga"] = {9},
    ["10H.tga"] = {10},
    ["JH.tga"] = {10},
    ["QH.tga"] = {10},
    ["KH.tga"] = {10},
    ["AC.tga"] = {1, 11},
    ["2C.tga"] = {2},
    ["3C.tga"] = {3},
    ["4C.tga"] = {4},
    ["5C.tga"] = {5},
    ["6C.tga"] = {6},
    ["7C.tga"] = {7},
    ["8C.tga"] = {8},
    ["9C.tga"] = {9},
    ["10C.tga"] = {10},
    ["JC.tga"] = {10},
    ["QC.tga"] = {10},
    ["KC.tga"] = {10},
    ["AS.tga"] = {1, 11},
    ["2S.tga"] = {2},
    ["3S.tga"] = {3},
    ["4S.tga"] = {4},
    ["5S.tga"] = {5},
    ["6S.tga"] = {6},
    ["7S.tga"] = {7},
    ["8S.tga"] = {8},
    ["9S.tga"] = {9},
    ["10S.tga"] = {10},
    ["JS.tga"] = {10},
    ["QS.tga"] = {10},
    ["KS.tga"] = {10},
}

turnDAO = 0

player1ActiveDAO = false
player1ResultAnnouncedDAO = false
player1SplitResultAnnouncedDAO = false
player1SplitH2ResultAnnouncedDAO = false
player1PPSideBetWinDAO = false
player1213SideBetWinDAO = false
player1SplitToggleDAO = false
player1SplitOfferedDAO = false
player1RunningTotalDAO = 0
player1RunningTotalWithAceDAO = 0
player1S1RunningTotalDAO = 0
player1S1RunningTotalWithAceDAO = 0
player1S2RunningTotalDAO = 0
player1S2RunningTotalWithAceDAO = 0
player1TotalBetAmountDAO = 0
player1BankingTotalWageredDAO = 0
player1BankingTotalWonDAO = 0
player1BankingTotalLostDAO = 0
player1BankingTotalProfitDAO = 0
player1BankingBankrollDAO = 0

player2ActiveDAO = false
player2ResultAnnouncedDAO = false
player2SplitResultAnnouncedDAO = false
player2SplitH2ResultAnnouncedDAO = false
player2PPSideBetWinDAO = false
player2213SideBetWinDAO = false
player2SplitToggleDAO = false
player2SplitOfferedDAO = false
player2RunningTotalDAO = 0
player2RunningTotalWithAceDAO = 0
player2S1RunningTotalDAO = 0
player2S1RunningTotalWithAceDAO = 0
player2S2RunningTotalDAO = 0
player2S2RunningTotalWithAceDAO = 0
player2TotalBetAmountDAO = 0
player2BankingTotalWageredDAO = 0
player2BankingTotalWonDAO = 0
player2BankingTotalLostDAO = 0
player2BankingTotalProfitDAO = 0
player2BankingBankrollDAO = 0

player3ActiveDAO = false
player3ResultAnnouncedDAO = false
player3SplitResultAnnouncedDAO = false
player3SplitH2ResultAnnouncedDAO = false
player3PPSideBetWinDAO = false
player3213SideBetWinDAO = false
player3SplitToggleDAO = false
player3SplitOfferedDAO = false
player3RunningTotalDAO = 0
player3RunningTotalWithAceDAO = 0
player3S1RunningTotalDAO = 0
player3S1RunningTotalWithAceDAO = 0
player3S2RunningTotalDAO = 0
player3S2RunningTotalWithAceDAO = 0
player3TotalBetAmountDAO = 0
player3BankingTotalWageredDAO = 0
player3BankingTotalWonDAO = 0
player3BankingTotalLostDAO = 0
player3BankingTotalProfitDAO = 0
player3BankingBankrollDAO = 0

player4ActiveDAO = false
player4ResultAnnouncedDAO = false
player4SplitResultAnnouncedDAO = false
player4SplitH2ResultAnnouncedDAO = false
player4PPSideBetWinDAO = false
player4213SideBetWinDAO = false
player4SplitToggleDAO = false
player4SplitOfferedDAO = false
player4RunningTotalDAO = 0
player4RunningTotalWithAceDAO = 0
player4S1RunningTotalDAO = 0
player4S1RunningTotalWithAceDAO = 0
player4S2RunningTotalDAO = 0
player4S2RunningTotalWithAceDAO = 0
player4TotalBetAmountDAO = 0
player4BankingTotalWageredDAO = 0
player4BankingTotalWonDAO = 0
player4BankingTotalLostDAO = 0
player4BankingTotalProfitDAO = 0
player4BankingBankrollDAO = 0

player5ActiveDAO = false
player5ResultAnnouncedDAO = false
player5SplitResultAnnouncedDAO = false
player5SplitH2ResultAnnouncedDAO = false
player5PPSideBetWinDAO = false
player5213SideBetWinDAO = false
player5SplitToggleDAO = false
player5SplitOfferedDAO = false
player5RunningTotalDAO = 0
player5RunningTotalWithAceDAO = 0
player5S1RunningTotalDAO = 0
player5S1RunningTotalWithAceDAO = 0
player5S2RunningTotalDAO = 0
player5S2RunningTotalWithAceDAO = 0
player5TotalBetAmountDAO = 0
player5BankingTotalWageredDAO = 0
player5BankingTotalWonDAO = 0
player5BankingTotalLostDAO = 0
player5BankingTotalProfitDAO = 0
player5BankingBankrollDAO = 0

dealerRunningTotalDAO = 0
dealerRunningTotalWithAceDAO = 0

countdownNumber = 0
countdownNumber2 = 4
countdownDurationDAO = 30

countdownDurationResults1DAO = 3
countdownResult1DAO = 3
countdownDurationResults2DAO = 3
countdownResult2DAO = 3
countdownDurationResults3DAO = 3
countdownResult3DAO = 3
countdownDurationResults4DAO = 3
countdownResult4DAO = 3
countdownDurationResults5DAO = 3
countdownResult5DAO = 3

countdownDurationResults12DAO = 6
countdownResult12DAO = 6
countdownDurationResults13DAO = 6
countdownResult13DAO = 6
countdownDurationResults14DAO = 6
countdownResult14DAO = 6
countdownDurationResults15DAO = 6
countdownResult15DAO = 6
countdownDurationResults23DAO = 6
countdownResult23DAO = 6
countdownDurationResults24DAO = 6
countdownResult24DAO = 6
countdownDurationResults25DAO = 6
countdownResult25DAO = 6
countdownDurationResults34DAO = 6
countdownResult34DAO = 6
countdownDurationResults35DAO = 6
countdownResult35DAO = 6
countdownDurationResults45DAO = 6
countdownResult45DAO = 6

countdownDurationResults123DAO = 9
countdownResult123DAO = 9
countdownDurationResults124DAO = 9
countdownResult124DAO = 9
countdownDurationResults125DAO = 9
countdownResult125DAO = 9
countdownDurationResults134DAO = 9
countdownResult134DAO = 9
countdownDurationResults135DAO = 9
countdownResult135DAO = 9
countdownDurationResults145DAO = 9
countdownResult145DAO = 9
countdownDurationResults234DAO = 9
countdownResult234DAO = 9
countdownDurationResults235DAO = 9
countdownResult235DAO = 9
countdownDurationResults245DAO = 9
countdownResult245DAO = 9
countdownDurationResults345DAO = 9
countdownResult345DAO = 9

countdownDurationResults1234DAO = 12
countdownResult1234DAO = 12
countdownDurationResults1235DAO = 12
countdownResult1235DAO = 12
countdownDurationResults1245DAO = 12
countdownResult1245DAO = 12
countdownDurationResults1345DAO = 12
countdownResult1345DAO = 12
countdownDurationResults2345DAO = 12
countdownResult2345DAO = 12

countdownDurationResults12345DAO = 15
countdownResult12345DAO = 16

mixedPairPayoutDAO = 5
mixedPairPayoutReturnDAO = mixedPairPayoutDAO + 1
colouredPairPayoutDAO = 10
colouredPairPayoutReturnDAO = colouredPairPayoutDAO + 1
perfectPairPayoutDAO = 25
perfectPairPayoutReturnDAO = perfectPairPayoutDAO + 1
flushPayoutDAO = 5
flushPayoutReturnDAO = flushPayoutDAO + 1
straightPayoutDAO = 10
straightPayoutReturnDAO = straightPayoutDAO + 1
threeOfAKindPayoutDAO = 25
threeOfAKindPayoutReturnDAO = threeOfAKindPayoutDAO + 1
straightFlushPayoutDAO = 40
straightFlushPayoutReturnDAO = straightFlushPayoutDAO + 1
suitedThreeOfAKindPayoutDAO = 100
suitedThreeOfAKindPayoutReturnDAO = suitedThreeOfAKindPayoutDAO + 1

cardImagesDAO = {}
dealtCardsDAO = {}

playerBankingInfoDAO = {}

soundFilesDAO = {
    "1", "2", "3", "4", "5", "6", "7", "8", "9", "10",
    "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21",
    "1 or 11", "2 or 12", "3 or 13", "4 or 14", "5 or 15", "6 or 16", -- 22, 23, 24, 25, 26, 27
    "7 or 17", "8 or 18", "9 or 19", "10 or 20", -- 28, 29, 30, 31

    "DealingCard", "ConfirmBet", -- 32, 33
    "Hit", "Stand", "Double", "Split", -- 34, 35, 36, 37

    "Player1Blackjack", "Player1Win", "Player1Push", "Player1Loss", "Player1Bust", -- 38, 39, 40, 41, 42
    "Player1SplitWinWin", "Player1SplitWinPush", "Player1SplitWinLoss", -- 43, 44, 45
    "Player1SplitPushWin", "Player1SplitPushPush", "Player1SplitPushLoss", -- 46, 47, 48
    "Player1SplitLossWin", "Player1SplitLossPush", "Player1SplitLossLoss", -- 49, 50, 51

    "Player2Blackjack", "Player2Win", "Player2Push", "Player2Loss", "Player2Bust", -- 52, 53, 54, 55, 56
    "Player2SplitWinWin", "Player2SplitWinPush", "Player2SplitWinLoss", -- 57, 58, 59
    "Player2SplitPushWin", "Player2SplitPushPush", "Player2SplitPushLoss", -- 60, 61, 62
    "Player2SplitLossWin", "Player2SplitLossPush", "Player2SplitLossLoss", -- 63, 64, 65
    
    "Player3Blackjack", "Player3Win", "Player3Push", "Player3Loss", "Player3Bust", -- 66, 67, 68, 69, 70
    "Player3SplitWinWin", "Player3SplitWinPush", "Player3SplitWinLoss", -- 71, 72, 73
    "Player3SplitPushWin", "Player3SplitPushPush", "Player3SplitPushLoss", -- 74, 75, 76
    "Player3SplitLossWin", "Player3SplitLossPush", "Player3SplitLossLoss", -- 77, 78, 79

    "Player4Blackjack", "Player4Win", "Player4Push", "Player4Loss", "Player4Bust", -- 80, 81, 82, 83, 84
    "Player4SplitWinWin", "Player4SplitWinPush", "Player4SplitWinLoss", -- 85, 86, 87
    "Player4SplitPushWin", "Player4SplitPushPush", "Player4SplitPushLoss", -- 88, 89, 90
    "Player4SplitLossWin", "Player4SplitLossPush", "Player4SplitLossLoss", -- 91, 92, 93

    "Player5Blackjack", "Player5Win", "Player5Push", "Player5Loss", "Player5Bust", -- 94, 95, 96, 97, 98
    "Player5SplitWinWin", "Player5SplitWinPush", "Player5SplitWinLoss", -- 99, 100, 101
    "Player5SplitPushWin", "Player5SplitPushPush", "Player5SplitPushLoss", -- 102, 103, 104
    "Player5SplitLossWin", "Player5SplitLossPush", "Player5SplitLossLoss", -- 105, 106, 107

    "AllPlayersWin", "AllPlayersPush", "AllPlayersLoss", -- 108, 109, 110

    "DealerBlackjack", "DealerBust" -- 111, 112

}

soundFilePathsDAO = {}

for i, fileNameDAO in ipairs(soundFilesDAO) do
    soundFilePathsDAO[i] = "Interface\\AddOns\\BlackjackDealer\\Sounds\\" .. fileNameDAO .. ".mp3"
end

cardSetsDAO = {
    [1] = {"AD.tga", "AH.tga", "AS.tga", "AC.tga"},
    [2] = {"2D.tga", "2H.tga", "2S.tga", "2C.tga"},
    [3] = {"3D.tga", "3H.tga", "3S.tga", "3C.tga"},
    [4] = {"4D.tga", "4H.tga", "4S.tga", "4C.tga"},
    [5] = {"5D.tga", "5H.tga", "5S.tga", "5C.tga"},
    [6] = {"6D.tga", "6H.tga", "6S.tga", "6C.tga"},
    [7] = {"7D.tga", "7H.tga", "7S.tga", "7C.tga"},
    [8] = {"8D.tga", "8H.tga", "8S.tga", "8C.tga"},
    [9] = {"9D.tga", "9H.tga", "9S.tga", "9C.tga"},
    [10] = {"10D.tga", "10H.tga", "10S.tga", "10C.tga"},
    [11] = {"JD.tga", "JH.tga", "JS.tga", "JC.tga"},
    [12] = {"QD.tga", "QH.tga", "QS.tga", "QC.tga"},
    [13] = {"KD.tga", "KH.tga", "KS.tga", "KC.tga"},
}

originalCurrentRollDAO = 312
currentRollDAO = originalCurrentRollDAO

originalCardTableDAO = {}
suitsDAO = {"Spades", "Clubs", "Hearts", "Diamonds"}
ranksDAO = {"Ace", "2", "3", "4", "5", "6", "7", "8", "9", "10", "Jack", "Queen", "King"}

for deckDAO = 1, 6 do
    for suitIndexDAO, suitDAO in ipairs(suitsDAO) do
        for rankIndexDAO, rankDAO in ipairs(ranksDAO) do
            local cardNameDAO

            if rankDAO == "Ace" then
                cardNameDAO = "Ace of " .. suitDAO .. " (1 or 11)"
            elseif rankDAO == "Jack" or rankDAO == "Queen" or rankDAO == "King" then
                cardNameDAO = rankDAO .. " of " .. suitDAO .. " (10)"
            else
                cardNameDAO = rankDAO .. " of " .. suitDAO
            end

            table.insert(originalCardTableDAO, cardNameDAO)
        end
    end
end

cardValuesDAO = {
    ["AD.tga"] = {1, 11},
    ["2D.tga"] = {2},
    ["3D.tga"] = {3},
    ["4D.tga"] = {4},
    ["5D.tga"] = {5},
    ["6D.tga"] = {6},
    ["7D.tga"] = {7},
    ["8D.tga"] = {8},
    ["9D.tga"] = {9},
    ["10D.tga"] = {10},
    ["JD.tga"] = {10},
    ["QD.tga"] = {10},
    ["KD.tga"] = {10},
    ["AH.tga"] = {1, 11},
    ["2H.tga"] = {2},
    ["3H.tga"] = {3},
    ["4H.tga"] = {4},
    ["5H.tga"] = {5},
    ["6H.tga"] = {6},
    ["7H.tga"] = {7},
    ["8H.tga"] = {8},
    ["9H.tga"] = {9},
    ["10H.tga"] = {10},
    ["JH.tga"] = {10},
    ["QH.tga"] = {10},
    ["KH.tga"] = {10},
    ["AC.tga"] = {1, 11},
    ["2C.tga"] = {2},
    ["3C.tga"] = {3},
    ["4C.tga"] = {4},
    ["5C.tga"] = {5},
    ["6C.tga"] = {6},
    ["7C.tga"] = {7},
    ["8C.tga"] = {8},
    ["9C.tga"] = {9},
    ["10C.tga"] = {10},
    ["JC.tga"] = {10},
    ["QC.tga"] = {10},
    ["KC.tga"] = {10},
    ["AS.tga"] = {1, 11},
    ["2S.tga"] = {2},
    ["3S.tga"] = {3},
    ["4S.tga"] = {4},
    ["5S.tga"] = {5},
    ["6S.tga"] = {6},
    ["7S.tga"] = {7},
    ["8S.tga"] = {8},
    ["9S.tga"] = {9},
    ["10S.tga"] = {10},
    ["JS.tga"] = {10},
    ["QS.tga"] = {10},
    ["KS.tga"] = {10},
}

cardNamesDAO = {
    ["AD.tga"] = "Ace of Diamonds (1 or 11)",
    ["2D.tga"] = "2 of Diamonds",
    ["3D.tga"] = "3 of Diamonds",
    ["4D.tga"] = "4 of Diamonds",
    ["5D.tga"] = "5 of Diamonds",
    ["6D.tga"] = "6 of Diamonds",
    ["7D.tga"] = "7 of Diamonds",
    ["8D.tga"] = "8 of Diamonds",
    ["9D.tga"] = "9 of Diamonds",
    ["10D.tga"] = "10 of Diamonds",
    ["JD.tga"] = "Jack of Diamonds (10)",
    ["QD.tga"] = "Queen of Diamonds (10)",
    ["KD.tga"] = "King of Diamonds (10)",
    ["AH.tga"] = "Ace of Hearts (1 or 11)",
    ["2H.tga"] = "2 of Hearts",
    ["3H.tga"] = "3 of Hearts",
    ["4H.tga"] = "4 of Hearts",
    ["5H.tga"] = "5 of Hearts",
    ["6H.tga"] = "6 of Hearts",
    ["7H.tga"] = "7 of Hearts",
    ["8H.tga"] = "8 of Hearts",
    ["9H.tga"] = "9 of Hearts",
    ["10H.tga"] = "10 of Hearts",
    ["JH.tga"] = "Jack of Hearts (10)",
    ["QH.tga"] = "Queen of Hearts (10)",
    ["KH.tga"] = "King of Hearts (10)",
    ["AC.tga"] = "Ace of Clubs (1 or 11)",
    ["2C.tga"] = "2 of Clubs",
    ["3C.tga"] = "3 of Clubs",
    ["4C.tga"] = "4 of Clubs",
    ["5C.tga"] = "5 of Clubs",
    ["6C.tga"] = "6 of Clubs",
    ["7C.tga"] = "7 of Clubs",
    ["8C.tga"] = "8 of Clubs",
    ["9C.tga"] = "9 of Clubs",
    ["10C.tga"] = "10 of Clubs",
    ["JC.tga"] = "Jack of Clubs (10)",
    ["QC.tga"] = "Queen of Clubs (10)",
    ["KC.tga"] = "King of Clubs (10)",
    ["AS.tga"] = "Ace of Spades (1 or 11)",
    ["2S.tga"] = "2 of Spades",
    ["3S.tga"] = "3 of Spades",
    ["4S.tga"] = "4 of Spades",
    ["5S.tga"] = "5 of Spades",
    ["6S.tga"] = "6 of Spades",
    ["7S.tga"] = "7 of Spades",
    ["8S.tga"] = "8 of Spades",
    ["9S.tga"] = "9 of Spades",
    ["10S.tga"] = "10 of Spades",
    ["JS.tga"] = "Jack of Spades (10)",
    ["QS.tga"] = "Queen of Spades (10)",
    ["KS.tga"] = "King of Spades (10)",
}




















-- >> PLAYERFRAME <<
-- >> PLAYERFRAME <<
-- >> PLAYERFRAME <<

-- Creating the main playerFrame
playerFrame = CreateFrame("Frame", "BlackjackPlayerFrame", UIParent, "BasicFrameTemplateWithInset")
playerFrame:SetSize(1280, 720)
playerFrame:SetPoint("CENTER")
playerFrame:SetFrameStrata("HIGH")
playerFrame:SetFrameLevel(playerFrame:GetFrameLevel() + 1)
playerFrame:Hide()

-- Setting a title
playerFrame.title = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.title:SetPoint("TOP", playerFrame, 0, -5)
playerFrame.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

-- Setting background texture (Blackjack Table)
backgroundImage = playerFrame:CreateTexture(nil, "BACKGROUND")
backgroundImage:SetSize(2048, 1024)
backgroundImage:SetPoint("TOP", playerFrame, "TOP", 17, 187)
backgroundImage:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\blackjackplayerupdated.tga")
backgroundImage:SetBlendMode("BLEND")
backgroundImage:SetDrawLayer("ARTWORK")

-- "Menu" button which presents other buttons
playerFrame.menuButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.menuButton:SetPoint("TOPRIGHT", playerFrame, -23, -40)
playerFrame.menuButton:SetSize(80, 30)
playerFrame.menuButton:SetText("Menu")

-- "Tip Dealer" button which links to the Discord
playerFrame.tipButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.tipButton:SetPoint("TOP", playerFrame, 230, -73)
playerFrame.tipButton:SetSize(80, 30)
playerFrame.tipButton:SetText("Tip Dealer")
playerFrame.tipButton:Disable()

-- Tip Dealer Amount
tipDealerEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
tipDealerEditBox:SetSize(40, 30)
tipDealerEditBox:SetPoint("TOP", playerFrame, 166, -73)
tipDealerEditBox:SetAutoFocus(false)
tipDealerEditBox:SetNumeric(true)
tipDealerEditBox:Disable()

-- Function to handle the "Tip Dealer" button
function tipDealerButtonClick()
    playerTip = tonumber(tipDealerEditBox:GetText())
    if playerName == unitName1 then
        player1currentBankroll = tonumber(string.match(bankrollFrame.player1TotalBankrollTableDisplay:GetText(), "%d+"))
        if playerTip >= 1 and player1currentBankroll - playerTip < 0 then
            print("You do not have enough gold in your bankroll to leave that tip. Please visit the Cash Desk.")
        else
            SendChatMessage("[P1] {star} l have tipped the DeaIer " .. playerTip .. "G.", "RAID")
            tipDealerEditBox:SetText("")
            tipDealerEditBox:ClearFocus()
            tipDealerEditBox:SetFocus(false)
            PlaySoundFile(soundFilePaths[33])

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(playerTip)
                bankingInfo.bankrollTable = player1TotalBankrollAmount
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        end
    elseif playerName == unitName2 then
        player2currentBankroll = tonumber(string.match(bankrollFrame.player2TotalBankrollTableDisplay:GetText(), "%d+"))
        if playerTip >= 1 and player2currentBankroll - playerTip < 0 then
            print("You do not have enough gold in your bankroll to leave that tip. Please visit the Cash Desk.")
        else
            SendChatMessage("[P2] {star} l have tipped the DeaIer " .. playerTip .. "G.", "RAID")
            tipDealerEditBox:SetText("")
            tipDealerEditBox:ClearFocus()
            tipDealerEditBox:SetFocus(false)
            PlaySoundFile(soundFilePaths[33])

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(playerTip)
                bankingInfo.bankrollTable = player2TotalBankrollAmount
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        end
    elseif playerName == unitName3 then
        player3currentBankroll = tonumber(string.match(bankrollFrame.player3TotalBankrollTableDisplay:GetText(), "%d+"))
        if playerTip >= 1 and player3currentBankroll - playerTip < 0 then
            print("You do not have enough gold in your bankroll to leave that tip. Please visit the Cash Desk.")
        else
            SendChatMessage("[P3] {star} l have tipped the DeaIer " .. playerTip .. "G.", "RAID")
            tipDealerEditBox:SetText("")
            tipDealerEditBox:ClearFocus()
            tipDealerEditBox:SetFocus(false)
            PlaySoundFile(soundFilePaths[33])

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(playerTip)
                bankingInfo.bankrollTable = player3TotalBankrollAmount
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        end
    elseif playerName == unitName4 then
        player4currentBankroll = tonumber(string.match(bankrollFrame.player4TotalBankrollTableDisplay:GetText(), "%d+"))
        if playerTip >= 1 and player4currentBankroll - playerTip < 0 then
            print("You do not have enough gold in your bankroll to leave that tip. Please visit the Cash Desk.")
        else
            SendChatMessage("[P4] {star} l have tipped the DeaIer " .. playerTip .. "G.", "RAID")
            tipDealerEditBox:SetText("")
            tipDealerEditBox:ClearFocus()
            tipDealerEditBox:SetFocus(false)
            PlaySoundFile(soundFilePaths[33])

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(playerTip)
                bankingInfo.bankrollTable = player4TotalBankrollAmount
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        end
    elseif playerName == unitName5 then
        player5currentBankroll = tonumber(string.match(bankrollFrame.player5TotalBankrollTableDisplay:GetText(), "%d+"))
        if playerTip >= 1 and player5currentBankroll - playerTip < 0 then
            print("You do not have enough gold in your bankroll to leave that tip. Please visit the Cash Desk.")
        else
            SendChatMessage("[P5] {star} l have tipped the DeaIer " .. playerTip .. "G.", "RAID")
            tipDealerEditBox:SetText("")
            tipDealerEditBox:ClearFocus()
            tipDealerEditBox:SetFocus(false)
            PlaySoundFile(soundFilePaths[33])

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(playerTip)
                bankingInfo.bankrollTable = player5TotalBankrollAmount
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        end
    end
end

-- "Tip Dealer" button
playerFrame.tipButton:SetScript("OnClick", tipDealerButtonClick)

-- "Discord" button which links to the Discord
playerFrame.discordButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.discordButton:SetPoint("TOP", playerFrame, 205, -40)
playerFrame.discordButton:SetSize(134, 30)
playerFrame.discordButton:SetText("Join Discord")

playerFrame.discordButton:SetScript("OnClick", function()
    StaticPopupDialogs["DISCORD_LINK"] = {
        text = "Copy the link below to join our Discord:",
        button1 = "Close",
        hasEditBox = true,
        hasWideEditBox = true,
        editBoxWidth = 260,
        timeout = 0,
        whileDead = true,
        hideOnEscape = true,
        preferredIndex = STATICPOPUP_NUMDIALOGS,
    }

    dialog = StaticPopup_Show("DISCORD_LINK")
    dialog.editBox:SetText("https://discord.gg/mpzpBwpY2w")
    dialog.editBox:SetFocus()
    dialog.editBox:HighlightText()
end)

-- "History" button which shows Profit/Loss in real-time
playerFrame.historyButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.historyButton:SetPoint("TOPRIGHT", playerFrame, -23, -123)
playerFrame.historyButton:SetSize(80, 30)
playerFrame.historyButton:SetText("History")
playerFrame.historyButton:Disable()
playerFrame.historyButton:Hide()

-- "Cash Desk" button which displays the Cash Desk screen
playerFrame.cashDeskButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.cashDeskButton:SetPoint("BOTTOMLEFT", playerFrame, 17, 200)
playerFrame.cashDeskButton:SetSize(85, 30)
playerFrame.cashDeskButton:SetText("Cash Desk")
playerFrame.cashDeskButton:Disable()

-- "Take Seat" button to sit down at Seat 1
playerFrame.takeSeat1Button = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.takeSeat1Button:SetPoint("CENTER", playerFrame, 450, -70)
playerFrame.takeSeat1Button:SetSize(85, 30)
playerFrame.takeSeat1Button:SetText("Take Seat")

-- "Leave Seat" button to exit Seat 1
playerFrame.leaveSeat1Button = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.leaveSeat1Button:SetPoint("CENTER", playerFrame, 556, -85)
playerFrame.leaveSeat1Button:SetSize(75, 30)
playerFrame.leaveSeat1Button:SetText("Exit Seat")
playerFrame.leaveSeat1Button:Hide()

-- "Take Seat" button to sit down at Seat 2
playerFrame.takeSeat2Button = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.takeSeat2Button:SetPoint("CENTER", playerFrame, 254, -218)
playerFrame.takeSeat2Button:SetSize(85, 30)
playerFrame.takeSeat2Button:SetText("Take Seat")

-- "Leave Seat" button to exit Seat 2
playerFrame.leaveSeat2Button = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.leaveSeat2Button:SetPoint("CENTER", playerFrame, 360, -233)
playerFrame.leaveSeat2Button:SetSize(75, 30)
playerFrame.leaveSeat2Button:SetText("Exit Seat")
playerFrame.leaveSeat2Button:Hide()

-- "Take Seat" button to sit down at Seat 3
playerFrame.takeSeat3Button = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.takeSeat3Button:SetPoint("CENTER", playerFrame, 0, -265)
playerFrame.takeSeat3Button:SetSize(85, 30)
playerFrame.takeSeat3Button:SetText("Take Seat")

-- "Leave Seat" button to exit Seat 3
playerFrame.leaveSeat3Button = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.leaveSeat3Button:SetPoint("CENTER", playerFrame, 106, -280)
playerFrame.leaveSeat3Button:SetSize(75, 30)
playerFrame.leaveSeat3Button:SetText("Exit Seat")
playerFrame.leaveSeat3Button:Hide()

-- "Take Seat" button to sit down at Seat 4
playerFrame.takeSeat4Button = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.takeSeat4Button:SetPoint("CENTER", playerFrame, -256, -210)
playerFrame.takeSeat4Button:SetSize(85, 30)
playerFrame.takeSeat4Button:SetText("Take Seat")

-- "Leave Seat" button to exit Seat 4
playerFrame.leaveSeat4Button = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.leaveSeat4Button:SetPoint("CENTER", playerFrame, -150, -225)
playerFrame.leaveSeat4Button:SetSize(75, 30)
playerFrame.leaveSeat4Button:SetText("Exit Seat")
playerFrame.leaveSeat4Button:Hide()

-- "Take Seat" button to sit down at Seat 5
playerFrame.takeSeat5Button = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.takeSeat5Button:SetPoint("CENTER", playerFrame, -440, -70)
playerFrame.takeSeat5Button:SetSize(85, 30)
playerFrame.takeSeat5Button:SetText("Take Seat")

-- "Leave Seat" button to exit Seat 5
playerFrame.leaveSeat5Button = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.leaveSeat5Button:SetPoint("CENTER", playerFrame, -334, -85)
playerFrame.leaveSeat5Button:SetSize(75, 30)
playerFrame.leaveSeat5Button:SetText("Exit Seat")
playerFrame.leaveSeat5Button:Hide()

-- "Leave Table" button
playerFrame.leaveTableButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.leaveTableButton:SetPoint("TOPLEFT", playerFrame, 23, -40)
playerFrame.leaveTableButton:SetSize(85, 30)
playerFrame.leaveTableButton:SetText("Leave Table")
playerFrame.leaveTableButton:SetNormalFontObject("GameFontWhiteSmall")
playerFrame.leaveTableButton:SetHighlightFontObject("GameFontWhiteSmall")

-- Dealer Card Total Text
playerFrame.dealerCardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.dealerCardTotalText:SetPoint("TOP", playerFrame, "TOP", -65, -148)
playerFrame.dealerCardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 28, "OUTLINE") -- Adjust the font and size as needed
playerFrame.dealerCardTotalText:SetText("")

-- Enabling click-and-drag functionality
playerFrame:SetMovable(true)
playerFrame:EnableMouse(true)
playerFrame:RegisterForDrag("LeftButton")

-- Script for handling the drag of playerFrame
playerFrame:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

playerFrame:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)


-- Bankroll frame in the bottom-left of playerFrame
bankrollFrame = CreateFrame("Frame", "BlackjackBankrollFrame", playerFrame, "GlowBorderTemplate")
bankrollFrame:SetSize(240, 40)
bankrollFrame:SetPoint("BOTTOMLEFT", playerFrame, 18, 18)
bankrollFrame:SetFrameStrata("HIGH")
bankrollFrame:SetFrameLevel(bankrollFrame:GetFrameLevel() + 100)

bankrollFrame.player1TotalBankrollTableDisplay = bankrollFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankrollFrame.player1TotalBankrollTableDisplay:SetPoint("LEFT", bankrollFrame, 9, 0)
bankrollFrame.player1TotalBankrollTableDisplay:SetJustifyH("LEFT")
bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: 0 G")
bankrollFrame.player1TotalBankrollTableDisplay:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
bankrollFrame.player1TotalBankrollTableDisplay:Hide()

bankrollFrame.player2TotalBankrollTableDisplay = bankrollFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankrollFrame.player2TotalBankrollTableDisplay:SetPoint("LEFT", bankrollFrame, 9, 0)
bankrollFrame.player2TotalBankrollTableDisplay:SetJustifyH("LEFT")
bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: 0 G")
bankrollFrame.player2TotalBankrollTableDisplay:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
bankrollFrame.player2TotalBankrollTableDisplay:Hide()

bankrollFrame.player3TotalBankrollTableDisplay = bankrollFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankrollFrame.player3TotalBankrollTableDisplay:SetPoint("LEFT", bankrollFrame, 9, 0)
bankrollFrame.player3TotalBankrollTableDisplay:SetJustifyH("LEFT")
bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: 0 G")
bankrollFrame.player3TotalBankrollTableDisplay:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
bankrollFrame.player3TotalBankrollTableDisplay:Hide()

bankrollFrame.player4TotalBankrollTableDisplay = bankrollFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankrollFrame.player4TotalBankrollTableDisplay:SetPoint("LEFT", bankrollFrame, 9, 0)
bankrollFrame.player4TotalBankrollTableDisplay:SetJustifyH("LEFT")
bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: 0 G")
bankrollFrame.player4TotalBankrollTableDisplay:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
bankrollFrame.player4TotalBankrollTableDisplay:Hide()

bankrollFrame.player5TotalBankrollTableDisplay = bankrollFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankrollFrame.player5TotalBankrollTableDisplay:SetPoint("LEFT", bankrollFrame, 9, 0)
bankrollFrame.player5TotalBankrollTableDisplay:SetJustifyH("LEFT")
bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: 0 G")
bankrollFrame.player5TotalBankrollTableDisplay:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
bankrollFrame.player5TotalBankrollTableDisplay:Hide()

bankrollFrame.BaseTextDisplay = bankrollFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankrollFrame.BaseTextDisplay:SetPoint("LEFT", bankrollFrame, 18, 1)
bankrollFrame.BaseTextDisplay:SetJustifyH("LEFT")
bankrollFrame.BaseTextDisplay:SetText("Sit down to deposit/withdraw")
bankrollFrame.BaseTextDisplay:SetFont("Fonts\\FRIZQT__.TTF", 13, "OUTLINE")
bankrollFrame.BaseTextDisplay:Show()

function FadeOut(frame)
    frame.fadeInfo = { mode = "OUT", timeToFade = fadeDuration, finishedFunc = function() end }
    UIFrameFade(frame, frame.fadeInfo)
end

function UpdateWinningsDisplay(frame, amount)
    frame:SetText("+" .. amount .. " G")
    frame:Show()

    FadeOut(frame)
end









-- MenuFrame in the top-right of the table UI
menuFrame = CreateFrame("Frame", "BlackjackMenuFrame", playerFrame, "InsetFrameTemplate")
menuFrame:SetSize(97, 255)
menuFrame:SetPoint("TOPRIGHT", playerFrame, -15, -88)
menuFrame:SetFrameStrata("HIGH")
menuFrame:SetFrameLevel(menuFrame:GetFrameLevel() + 100)
menuFrame:Hide()

-- "Rules" button which displays the rules of Blackjack
menuFrame.rulesButton = CreateFrame("Button", nil, menuFrame, "GameMenuButtonTemplate")
menuFrame.rulesButton:SetPoint("TOP", menuFrame, 0, -7)
menuFrame.rulesButton:SetSize(80, 30)
menuFrame.rulesButton:SetText("Rules")

-- "Payouts" button which shows side-bet combinations
menuFrame.payoutsButton = CreateFrame("Button", nil, menuFrame, "GameMenuButtonTemplate")
menuFrame.payoutsButton:SetPoint("TOP", menuFrame, 0, -40)
menuFrame.payoutsButton:SetSize(80, 30)
menuFrame.payoutsButton:SetText("Payouts")

-- "Preload" button which allows players to pre-load bets
menuFrame.preloadButton = CreateFrame("Button", nil, menuFrame, "GameMenuButtonTemplate")
menuFrame.preloadButton:SetPoint("TOP", menuFrame, 0, -73)
menuFrame.preloadButton:SetSize(80, 30)
menuFrame.preloadButton:SetText("Preload")
menuFrame.preloadButton:Disable()

-- "Cards" button which shows an enlarged image of dealt cards
menuFrame.cardsButton = CreateFrame("Button", nil, menuFrame, "GameMenuButtonTemplate")
menuFrame.cardsButton:SetPoint("TOP", menuFrame, 0, -106)
menuFrame.cardsButton:SetSize(80, 30)
menuFrame.cardsButton:SetText("Cards")
menuFrame.cardsButton:Disable()

-- "Emotes" button which allows players to use custom emotes
menuFrame.emotesButton = CreateFrame("Button", nil, menuFrame, "GameMenuButtonTemplate")
menuFrame.emotesButton:SetPoint("TOP", menuFrame, 0, -139)
menuFrame.emotesButton:SetSize(80, 30)
menuFrame.emotesButton:SetText("Emotes")
menuFrame.emotesButton:Disable()

-- "Chat Log" button which displays all Blackjack related messages from chat
menuFrame.chatLogButton = CreateFrame("Button", nil, menuFrame, "GameMenuButtonTemplate")
menuFrame.chatLogButton:SetPoint("TOP", menuFrame, 0, -172)
menuFrame.chatLogButton:SetSize(80, 30)
menuFrame.chatLogButton:SetText("Chat Log")

-- Volume slider
menuFrame.volumeSlider = CreateFrame("Slider", "BlackjackVolumeSlider", menuFrame, "OptionsSliderTemplate")
menuFrame.volumeSlider:SetWidth(72)
menuFrame.volumeSlider:SetHeight(17)
menuFrame.volumeSlider:SetPoint("TOP", menuFrame, 0, -222)
menuFrame.volumeSlider:SetMinMaxValues(0, 1)
menuFrame.volumeSlider:SetValueStep(0.01)
menuFrame.volumeSlider:SetObeyStepOnDrag(true)
menuFrame.volumeSlider:SetValue(GetCVar("Sound_MasterVolume"))

menuFrame.volumeSlider.textLow = _G[menuFrame.volumeSlider:GetName().."Low"];
menuFrame.volumeSlider.textHigh = _G[menuFrame.volumeSlider:GetName().."High"];
menuFrame.volumeSlider.text = _G[menuFrame.volumeSlider:GetName().."Text"];

menuFrame.volumeSlider.textLow:SetText("0%");
menuFrame.volumeSlider.textHigh:SetText("100%");
menuFrame.volumeSlider.text:SetText("Sounds");

menuFrame.volumeSlider:SetScript("OnValueChanged", function(self, value)
    SetCVar("Sound_MasterVolume", value);
    SetCVar("Sound_SFXVolume", value);
end);














-- Creating the numberOfDecks window
numberOfDecksFrame = CreateFrame("Frame", "TableLimitsPanelFrame", playerFrame, "InsetFrameTemplate")
numberOfDecksFrame:SetSize(240, 45)
numberOfDecksFrame:SetPoint("BOTTOMLEFT", playerFrame, 18, 148)
numberOfDecksFrame:SetAlpha(0.6)
numberOfDecksFrame:SetFrameStrata("TOOLTIP")

numberOfDecksTitleFrame = CreateFrame("Frame", "TableLimitsPanelFrame", numberOfDecksFrame, "InsetFrameTemplate")
numberOfDecksTitleFrame:SetSize(240, 24)
numberOfDecksTitleFrame:SetPoint("TOP", numberOfDecksFrame, 0, 0)
numberOfDecksTitleFrame:SetAlpha(0.35)
numberOfDecksTitleFrame:SetFrameStrata("TOOLTIP")

numberOfDecksTextFrame = CreateFrame("Frame", nil, playerFrame)
numberOfDecksTextFrame:SetAllPoints(numberOfDecksFrame)
numberOfDecksTextFrame:SetAlpha(1)
numberOfDecksTextFrame:SetFrameStrata("TOOLTIP")

numberOfDecksTextTitle = numberOfDecksTextFrame:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
numberOfDecksTextTitle:SetPoint("TOP", 4, -7)
numberOfDecksTextTitle:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
numberOfDecksTextTitle:SetText("Number of Decks")

numberOfDecksInShoeText = numberOfDecksTextFrame:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
numberOfDecksInShoeText:SetPoint("CENTER", 4, -10)
numberOfDecksInShoeText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
numberOfDecksInShoeText:SetText("6     (312 cards total)")
numberOfDecksInShoeText:SetTextColor(1, 0.992, 0.506)














-- Creating the tableLimits window as a child of playerFrame
tableLimitsFrame = CreateFrame("Frame", "TableLimitsPanelFrame", UIParent, "InsetFrameTemplate")
tableLimitsFrame:SetSize(240, 65)
tableLimitsFrame:SetPoint("BOTTOMLEFT", playerFrame, 18, 75)
tableLimitsFrame:SetAlpha(0.6)
tableLimitsFrame:SetFrameStrata("TOOLTIP")
tableLimitsFrame:Hide()

tableLimitsTitleFrame = CreateFrame("Frame", "TableLimitsPanelFrame", UIParent, "InsetFrameTemplate")
tableLimitsTitleFrame:SetSize(240, 24)
tableLimitsTitleFrame:SetPoint("TOP", tableLimitsFrame, 0, 0)
tableLimitsTitleFrame:SetFrameStrata("TOOLTIP")
tableLimitsTitleFrame:Hide()

tableLimitsTextFrame = CreateFrame("Frame", nil, UIParent)
tableLimitsTextFrame:SetAllPoints(tableLimitsFrame)
tableLimitsTextFrame:SetFrameStrata("TOOLTIP")
tableLimitsTextFrame:Hide()

tableLimitsTextTitle = tableLimitsTextFrame:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
tableLimitsTextTitle:SetPoint("TOP", 4, -7)
tableLimitsTextTitle:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tableLimitsTextTitle:SetText("Table Limits")

tableLimitsMainTitle = tableLimitsTextFrame:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
tableLimitsMainTitle:SetPoint("TOPLEFT", 47, -30)
tableLimitsMainTitle:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tableLimitsMainTitle:SetText("Main:")

tableLimitsMainText = tableLimitsTextFrame:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
tableLimitsMainText:SetPoint("TOPLEFT", 95, -30)
tableLimitsMainText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tableLimitsMainText:SetJustifyH("LEFT")
tableLimitsMainText:SetText("1000G  -  25000G")
tableLimitsMainText:SetTextColor(1, 0.992, 0.506)

tableLimitsSideTitle = tableLimitsTextFrame:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
tableLimitsSideTitle:SetPoint("TOPLEFT", 51, -46)
tableLimitsSideTitle:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tableLimitsSideTitle:SetText("Side:")

tableLimitsSideText = tableLimitsTextFrame:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
tableLimitsSideText:SetPoint("TOPLEFT", 95, -46)
tableLimitsSideText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tableLimitsSideText:SetJustifyH("LEFT")
tableLimitsSideText:SetText("100G  -  2500G")
tableLimitsSideText:SetTextColor(1, 0.992, 0.506)


















seatFrame = CreateFrame("Frame", "BlackjackSeatFrame", playerFrame)
seatFrame:SetSize(300, 80)
seatFrame:SetPoint("CENTER", playerFrame, 0, 100)
seatFrame:SetFrameStrata("HIGH")
seatFrame:SetFrameLevel(seatFrame:GetFrameLevel() + 100)
seatFrame:Hide()

seatFrameBackground = seatFrame:CreateTexture(nil, "BACKGROUND")
seatFrameBackground:SetAllPoints(seatFrame)
seatFrameBackground:SetColorTexture(0, 0, 0, 0.70)

seatFrame.seat1 = seatFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
seatFrame.seat1:SetPoint("CENTER", seatFrame, 0, 0)
seatFrame.seat1:SetFont("Fonts\\FRIZQT__.TTF", 24, "OUTLINE")
seatFrame.seat1:SetText("You have sat in |cFFFFD64CSeat 1|r\nYou are now |cFFFFD64CPlayer 1|r")
seatFrame.seat1:SetJustifyH("CENTER")
seatFrame.seat1:Hide()

seatFrame.seat2 = seatFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
seatFrame.seat2:SetPoint("CENTER", seatFrame, 0, 0)
seatFrame.seat2:SetFont("Fonts\\FRIZQT__.TTF", 24, "OUTLINE")
seatFrame.seat2:SetText("You have sat in |cFFFFD64CSeat 2|r\nYou are now |cFFFFD64CPlayer 2|r")
seatFrame.seat2:SetJustifyH("CENTER")
seatFrame.seat2:Hide()

seatFrame.seat3 = seatFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
seatFrame.seat3:SetPoint("CENTER", seatFrame, 0, 0)
seatFrame.seat3:SetFont("Fonts\\FRIZQT__.TTF", 24, "OUTLINE")
seatFrame.seat3:SetText("You have sat in |cFFFFD64CSeat 3|r\nYou are now |cFFFFD64CPlayer 3|r")
seatFrame.seat3:SetJustifyH("CENTER")
seatFrame.seat3:Hide()

seatFrame.seat4 = seatFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
seatFrame.seat4:SetPoint("CENTER", seatFrame, 0, 0)
seatFrame.seat4:SetFont("Fonts\\FRIZQT__.TTF", 24, "OUTLINE")
seatFrame.seat4:SetText("You have sat in |cFFFFD64CSeat 4|r\nYou are now |cFFFFD64CPlayer 4|r")
seatFrame.seat4:SetJustifyH("CENTER")
seatFrame.seat4:Hide()

seatFrame.seat5 = seatFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
seatFrame.seat5:SetPoint("CENTER", seatFrame, 0, 0)
seatFrame.seat5:SetFont("Fonts\\FRIZQT__.TTF", 24, "OUTLINE")
seatFrame.seat5:SetText("You have sat in |cFFFFD64CSeat 5|r\nYou are now |cFFFFD64CPlayer 5|r")
seatFrame.seat5:SetJustifyH("CENTER")
seatFrame.seat5:Hide()

function ResetSeatFrame1()
    seatFrameFadeInfo.mode = nil
    seatFrameFadeInfo.timeToFade = nil
    seatFrameFadeInfo.finishedFunc = nil
    seatFrameFadeInfo.finishedArg1 = nil
    seatFrameFadeInfo.finishedArg2 = nil

    seatFrame:SetScript("OnUpdate", nil)
end
function StartSeat1FadeOut()
    seatFrame:Show()
    seatFrame.seat1:SetAlpha(1)
    seatFrameBackground:SetAlpha(0.7)  -- Set initial alpha for background

    elapsedTime = 0

    seatFrame:SetScript("OnUpdate", function(_, elapsed)
        elapsedTime = elapsedTime + elapsed

        if elapsedTime >= seatFadeInfo.timeToFade then
            seatFrame:Hide()
            seatFrame:SetScript("OnUpdate", nil)
        else
            alpha = 1 - elapsedTime / seatFadeInfo.timeToFade
            seatFrame.seat1:SetAlpha(alpha)
            seatFrameBackground:SetAlpha(0.90 * alpha)  -- Adjust background alpha
        end
    end)
end

function ResetSeatFrame2()
    seatFrameFadeInfo.mode = nil
    seatFrameFadeInfo.timeToFade = nil
    seatFrameFadeInfo.finishedFunc = nil
    seatFrameFadeInfo.finishedArg1 = nil
    seatFrameFadeInfo.finishedArg2 = nil

    seatFrame:SetScript("OnUpdate", nil)
end
function StartSeat2FadeOut()
    seatFrame:Show()
    seatFrame.seat2:SetAlpha(1)
    seatFrameBackground:SetAlpha(0.7)  -- Set initial alpha for background

    elapsedTime = 0

    seatFrame:SetScript("OnUpdate", function(_, elapsed)
        elapsedTime = elapsedTime + elapsed

        if elapsedTime >= seatFadeInfo.timeToFade then
            seatFrame:Hide()
            seatFrame:SetScript("OnUpdate", nil)
        else
            alpha = 1 - elapsedTime / seatFadeInfo.timeToFade
            seatFrame.seat2:SetAlpha(alpha)
            seatFrameBackground:SetAlpha(0.90 * alpha)  -- Adjust background alpha
        end
    end)
end

function ResetSeatFrame3()
    seatFrameFadeInfo.mode = nil
    seatFrameFadeInfo.timeToFade = nil
    seatFrameFadeInfo.finishedFunc = nil
    seatFrameFadeInfo.finishedArg1 = nil
    seatFrameFadeInfo.finishedArg2 = nil

    seatFrame:SetScript("OnUpdate", nil)
end
function StartSeat3FadeOut()
    seatFrame:Show()
    seatFrame.seat3:SetAlpha(1)
    seatFrameBackground:SetAlpha(0.7)  -- Set initial alpha for background

    elapsedTime = 0

    seatFrame:SetScript("OnUpdate", function(_, elapsed)
        elapsedTime = elapsedTime + elapsed

        if elapsedTime >= seatFadeInfo.timeToFade then
            seatFrame:Hide()
            seatFrame:SetScript("OnUpdate", nil)
        else
            alpha = 1 - elapsedTime / seatFadeInfo.timeToFade
            seatFrame.seat3:SetAlpha(alpha)
            seatFrameBackground:SetAlpha(0.90 * alpha)  -- Adjust background alpha
        end
    end)
end

function ResetSeatFrame4()
    seatFrameFadeInfo.mode = nil
    seatFrameFadeInfo.timeToFade = nil
    seatFrameFadeInfo.finishedFunc = nil
    seatFrameFadeInfo.finishedArg1 = nil
    seatFrameFadeInfo.finishedArg2 = nil

    seatFrame:SetScript("OnUpdate", nil)
end
function StartSeat4FadeOut()
    seatFrame:Show()
    seatFrame.seat4:SetAlpha(1)
    seatFrameBackground:SetAlpha(0.7)  -- Set initial alpha for background

    elapsedTime = 0

    seatFrame:SetScript("OnUpdate", function(_, elapsed)
        elapsedTime = elapsedTime + elapsed

        if elapsedTime >= seatFadeInfo.timeToFade then
            seatFrame:Hide()
            seatFrame:SetScript("OnUpdate", nil)
        else
            alpha = 1 - elapsedTime / seatFadeInfo.timeToFade
            seatFrame.seat4:SetAlpha(alpha)
            seatFrameBackground:SetAlpha(0.90 * alpha)  -- Adjust background alpha
        end
    end)
end

function ResetSeatFrame5()
    seatFrameFadeInfo.mode = nil
    seatFrameFadeInfo.timeToFade = nil
    seatFrameFadeInfo.finishedFunc = nil
    seatFrameFadeInfo.finishedArg1 = nil
    seatFrameFadeInfo.finishedArg2 = nil

    seatFrame:SetScript("OnUpdate", nil)
end
function StartSeat5FadeOut()
    seatFrame:Show()
    seatFrame.seat5:SetAlpha(1)
    seatFrameBackground:SetAlpha(0.7)  -- Set initial alpha for background

    elapsedTime = 0

    seatFrame:SetScript("OnUpdate", function(_, elapsed)
        elapsedTime = elapsedTime + elapsed

        if elapsedTime >= seatFadeInfo.timeToFade then
            seatFrame:Hide()
            seatFrame:SetScript("OnUpdate", nil)
        else
            alpha = 1 - elapsedTime / seatFadeInfo.timeToFade
            seatFrame.seat5:SetAlpha(alpha)
            seatFrameBackground:SetAlpha(0.90 * alpha)  -- Adjust background alpha
        end
    end)
end













-- >> TIMER FRAME <<
-- >> TIMER FRAME <<
-- >> TIMER FRAME <<

timerFrame = CreateFrame("Frame", "BlackjackTimerFrame", playerFrame)
timerFrame:SetSize(210, 30)
timerFrame:SetPoint("TOP", playerFrame, 0, -65)
timerFrame:SetFrameStrata("HIGH")
timerFrame:SetFrameLevel(timerFrame:GetFrameLevel() + 100)
timerFrame:Hide()

timerFrameBackground = timerFrame:CreateTexture(nil, "BACKGROUND")
timerFrameBackground:SetAllPoints(timerFrame)
timerFrameBackground:SetColorTexture(0, 0, 0, 0.45)

timerBetsFrame = CreateFrame("Frame", "BlackjackTimerBetsFrame", playerFrame)
timerBetsFrame:SetSize(300, 80)
timerBetsFrame:SetPoint("CENTER", playerFrame, 0, 100)
timerBetsFrame:SetFrameStrata("HIGH")
timerBetsFrame:SetFrameLevel(15)
timerBetsFrame:Hide()

timerBetsFrameBackground = timerBetsFrame:CreateTexture(nil, "BACKGROUND")
timerBetsFrameBackground:SetAllPoints(timerBetsFrame)
timerBetsFrameBackground:SetColorTexture(0, 0, 0, 0.45)

-- Timer Limit 1
timerFrame.player1TimerText = timerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
timerFrame.player1TimerText:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
-- Timer Limit 2
timerFrame.player2TimerText = timerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
timerFrame.player2TimerText:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
-- Timer Limit 3
timerFrame.player3TimerText = timerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
timerFrame.player3TimerText:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
-- Timer Limit 4
timerFrame.player4TimerText = timerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
timerFrame.player4TimerText:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
-- Timer Limit 5
timerFrame.player5TimerText = timerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
timerFrame.player5TimerText:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
-- Timer Limit Bets
timerBetsFrame.timerTextBets = timerBetsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
timerBetsFrame.timerTextBets:SetPoint("CENTER", timerBetsFrame, 0, 0)
timerBetsFrame.timerTextBets:SetFont("Fonts\\FRIZQT__.TTF", 24, "OUTLINE")
timerBetsFrame.timerTextBets:SetJustifyH("CENTER")

























-- >> CASH DESK <<
-- >> CASH DESK <<
-- >> CASH DESK <<

-- Creating the cashDeskFrame window
cashDeskFrame = CreateFrame("Frame", "BlackjackCashDeskFrame", UIParent, "BasicFrameTemplateWithInset")
cashDeskFrame:SetSize(1080, 607)
cashDeskFrame:SetPoint("CENTER", playerFrame, 0, 0)
cashDeskFrame:SetFrameStrata("TOOLTIP")
cashDeskFrame:SetFrameLevel(tableLimitsFrame:GetFrameLevel() + 10)
cashDeskFrame:Hide()

-- Setting a title
cashDeskFrame.title = cashDeskFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
cashDeskFrame.title:SetPoint("TOP", cashDeskFrame, 0, -5)
cashDeskFrame.title:SetText("Blackjack v5.0.2 - Developed by Hyrav")

-- Setting background texture (Cash Desk)
cashDeskBackgroundImage = cashDeskFrame:CreateTexture(nil, "BACKGROUND")
cashDeskBackgroundImage:SetSize(1265, 603)
cashDeskBackgroundImage:SetPoint("CENTER", cashDeskFrame, -3, -11)
cashDeskBackgroundImage:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CashDeskBase.tga")
cashDeskBackgroundImage:SetBlendMode("BLEND")
cashDeskBackgroundImage:SetDrawLayer("ARTWORK")

-- Creating the Buy In button
cashDeskFrame.buyInButton = CreateFrame("Button", nil, cashDeskFrame, "GameMenuButtonTemplate")
cashDeskFrame.buyInButton:SetPoint("CENTER", cashDeskFrame, -130, -150)
cashDeskFrame.buyInButton:SetSize(150, 40)
cashDeskFrame.buyInButton:SetText("Buy-In")

-- Creating the Cash Out button
cashDeskFrame.cashOutButton = CreateFrame("Button", nil, cashDeskFrame, "GameMenuButtonTemplate")
cashDeskFrame.cashOutButton:SetPoint("CENTER", cashDeskFrame, 130, -150)
cashDeskFrame.cashOutButton:SetSize(150, 40)
cashDeskFrame.cashOutButton:SetText("Cash-Out")

-- Buy In Amount
buyInEditBox = CreateFrame("EditBox", nil, cashDeskFrame, "InputBoxTemplate")
buyInEditBox:SetSize(80, 30)
buyInEditBox:SetPoint("CENTER", cashDeskFrame, -135, -115)
buyInEditBox:SetAutoFocus(false)

cashDeskFrame.buyInAmountG = cashDeskFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
cashDeskFrame.buyInAmountG:SetPoint("CENTER", cashDeskFrame, -81, -114)
cashDeskFrame.buyInAmountG:SetText("G")
cashDeskFrame.buyInAmountG:SetJustifyH("CENTER")
cashDeskFrame.buyInAmountG:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")

-- Cash Out Amount
cashOutEditBox = CreateFrame("EditBox", nil, cashDeskFrame, "InputBoxTemplate")
cashOutEditBox:SetSize(80, 30)
cashOutEditBox:SetPoint("CENTER", cashDeskFrame, 125, -115)
cashOutEditBox:SetAutoFocus(false)

cashDeskFrame.buyInAmountG = cashDeskFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
cashDeskFrame.buyInAmountG:SetPoint("CENTER", cashDeskFrame, 178, -114)
cashDeskFrame.buyInAmountG:SetText("G")
cashDeskFrame.buyInAmountG:SetJustifyH("CENTER")
cashDeskFrame.buyInAmountG:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")

-- Create a "Join Table" button to start the game
cashDeskFrame.returnButton = CreateFrame("Button", nil, cashDeskFrame, "GameMenuButtonTemplate")
cashDeskFrame.returnButton:SetPoint("BOTTOMRIGHT", cashDeskFrame, -25, 45)
cashDeskFrame.returnButton:SetSize(120, 40)
cashDeskFrame.returnButton:SetText("Return")

-- Disclaimer text below leave table button
cashDeskFrame.DisclaimerText = cashDeskFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
cashDeskFrame.DisclaimerText:SetPoint("BOTTOM", cashDeskFrame, 0, 25)
cashDeskFrame.DisclaimerText:SetJustifyH("CENTER")
cashDeskFrame.DisclaimerText:SetText("Only stake what you can afford to lose.\nWhen the fun stops - stop immediately.")
cashDeskFrame.DisclaimerText:SetTextColor(1 , 0, 0)
cashDeskFrame.DisclaimerText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")

-- Bankroll
cashDeskFrame.player1TotalBankroll = cashDeskFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
cashDeskFrame.player1TotalBankroll:SetPoint("CENTER", cashDeskFrame, 0, -225)
cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: 0 G")
cashDeskFrame.player1TotalBankroll:SetJustifyH("CENTER")
cashDeskFrame.player1TotalBankroll:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
cashDeskFrame.player1TotalBankroll:Hide()

-- Bankroll
cashDeskFrame.player2TotalBankroll = cashDeskFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
cashDeskFrame.player2TotalBankroll:SetPoint("CENTER", cashDeskFrame, 0, -225)
cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: 0 G")
cashDeskFrame.player2TotalBankroll:SetJustifyH("CENTER")
cashDeskFrame.player2TotalBankroll:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
cashDeskFrame.player2TotalBankroll:Hide()

-- Bankroll
cashDeskFrame.player3TotalBankroll = cashDeskFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
cashDeskFrame.player3TotalBankroll:SetPoint("CENTER", cashDeskFrame, 0, -225)
cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: 0 G")
cashDeskFrame.player3TotalBankroll:SetJustifyH("CENTER")
cashDeskFrame.player3TotalBankroll:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
cashDeskFrame.player3TotalBankroll:Hide()

-- Bankroll
cashDeskFrame.player4TotalBankroll = cashDeskFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
cashDeskFrame.player4TotalBankroll:SetPoint("CENTER", cashDeskFrame, 0, -225)
cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: 0 G")
cashDeskFrame.player4TotalBankroll:SetJustifyH("CENTER")
cashDeskFrame.player4TotalBankroll:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
cashDeskFrame.player4TotalBankroll:Hide()

-- Bankroll
cashDeskFrame.player5TotalBankroll = cashDeskFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
cashDeskFrame.player5TotalBankroll:SetPoint("CENTER", cashDeskFrame, 0, -225)
cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: 0 G")
cashDeskFrame.player5TotalBankroll:SetJustifyH("CENTER")
cashDeskFrame.player5TotalBankroll:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
cashDeskFrame.player5TotalBankroll:Hide()

-- Player 1 Buy-In Function
function player1BuyIn()
    player1BuyInAmount = tonumber(buyInEditBox:GetText())
    if player1BuyInAmount and player1BuyInAmount >= minBetPP then

        buyInEditBox:SetFocus(false)
        buyInEditBox:ClearFocus()
        
        goldPart = math.floor(player1BuyInAmount)
        silverPart = (player1BuyInAmount - goldPart) * 100

        player1BuyInAmountGoldValue = goldPart * 10000 + silverPart * 100

        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/trade", chatFrame)
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:Insert("/trade")
        ChatEdit_SendText(editBox)
        C_Timer.After(1, function()
            if TradeFrame:IsShown() then
                -- Set the copper amount in the trade window
                MoneyInputFrame_SetCopper(TradePlayerInputMoneyFrame, player1BuyInAmountGoldValue)
                PlaySoundFile(soundFilePaths[33])
                -- Send the chat message only if the trade window is open
                SendChatMessage("{square} [P1] Buy-In for " .. player1BuyInAmount .. "G.", "RAID")
            else
                print("Please target (click on) the Dealer and try again!")
            end
            editBox:SetText("")
        end)

    else
        print("Please enter a value of at least 100G.")
    end

end
-- Player 1 Cash-Out Function
function player1CashOut()
    player1CashOutAmount = tonumber(cashOutEditBox:GetText()) -- Get the entered bet amount
    player1currentBankroll = tonumber(string.match(cashDeskFrame.player1TotalBankroll:GetText(), "%d+"))

    if player1CashOutAmount <= player1currentBankroll then

        cashOutEditBox:SetFocus(false)
        cashOutEditBox:ClearFocus()
        

        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/trade", chatFrame)
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:Insert("/trade")
        ChatEdit_SendText(editBox)

        C_Timer.After(1, function()
            if TradeFrame:IsShown() then
                PlaySoundFile(soundFilePaths[33])
                SendChatMessage("{square} [P1] Cash-Out for " .. player1CashOutAmount .. "G.", "RAID")
            else
                print("Please target (click on) the Dealer and try again!")
            end
            editBox:SetText("")
        end)
     
    else
        print("You don't have that much in your bankroll. Please choose a lower amount.")
    end

end
-- Player 2 Buy-In Function
function player2BuyIn()
    player2BuyInAmount = tonumber(buyInEditBox:GetText()) -- Get the entered bet amount
    if player2BuyInAmount and player2BuyInAmount >= minBetPP then
        
        buyInEditBox:SetFocus(false)
        buyInEditBox:ClearFocus()
        
        
        player2BuyInAmountGoldValue = player2BuyInAmount * 10000

        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/trade", chatFrame)
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:Insert("/trade")
        ChatEdit_SendText(editBox)
        C_Timer.After(1, function()
            if TradeFrame:IsShown() then
                -- Set the copper amount in the trade window
                MoneyInputFrame_SetCopper(TradePlayerInputMoneyFrame, player2BuyInAmountGoldValue)
                PlaySoundFile(soundFilePaths[33])
                -- Send the chat message only if the trade window is open
                SendChatMessage("{square} [P2] Buy-In for " .. player2BuyInAmount .. "G.", "RAID")
            else
                print("Please target (click on) the Dealer and try again!")
            end
            editBox:SetText("")
        end)
    else
        print("Please enter a value of at least 100G.")
    end

end
-- Player 2 Cash-Out Function
function player2CashOut()
    player2CashOutAmount = tonumber(cashOutEditBox:GetText()) -- Get the entered bet amount
    player2currentBankroll = tonumber(string.match(cashDeskFrame.player2TotalBankroll:GetText(), "%d+"))

    if player2CashOutAmount <= player2currentBankroll then

        cashOutEditBox:SetFocus(false)
        cashOutEditBox:ClearFocus()
        

        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/trade", chatFrame)
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:Insert("/trade")
        ChatEdit_SendText(editBox)

        C_Timer.After(1, function()
            if TradeFrame:IsShown() then
                PlaySoundFile(soundFilePaths[33])
                SendChatMessage("{square} [P2] Cash-Out for " .. player2CashOutAmount .. "G.", "RAID")
            else
                print("Please target (click on) the Dealer and try again!")
            end
            editBox:SetText("")
        end)
     
    else
        print("You don't have that much in your bankroll. Please choose a lower amount.")
    end

end
-- Player 3 Buy-In Function
function player3BuyIn()
    player3BuyInAmount = tonumber(buyInEditBox:GetText()) -- Get the entered bet amount
    if player3BuyInAmount and player3BuyInAmount >= minBetPP then
        
        buyInEditBox:SetFocus(false)
        buyInEditBox:ClearFocus()
        PlaySoundFile(soundFilePaths[33])
        
        player3BuyInAmountGoldValue = player3BuyInAmount * 10000

        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/trade", chatFrame)
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:Insert("/trade")
        ChatEdit_SendText(editBox)
        C_Timer.After(1, function()
            if TradeFrame:IsShown() then
                -- Set the copper amount in the trade window
                MoneyInputFrame_SetCopper(TradePlayerInputMoneyFrame, player3BuyInAmountGoldValue)
                
                -- Send the chat message only if the trade window is open
                SendChatMessage("{square} [P3] Buy-In for " .. player3BuyInAmount .. "G.", "RAID")
            else
                print("Please target (click on) the Dealer and try again!")
            end
            editBox:SetText("")
        end)
    else
        print("Please enter a value of at least 100G.")
    end

end
-- Player 3 Cash-Out Function
function player3CashOut()
    player3CashOutAmount = tonumber(cashOutEditBox:GetText()) -- Get the entered bet amount
    player3currentBankroll = tonumber(string.match(cashDeskFrame.player3TotalBankroll:GetText(), "%d+"))

    if player3CashOutAmount <= player3currentBankroll then

        cashOutEditBox:SetFocus(false)
        cashOutEditBox:ClearFocus()
        

        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/trade", chatFrame)
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:Insert("/trade")
        ChatEdit_SendText(editBox)

        C_Timer.After(1, function()
            if TradeFrame:IsShown() then
                PlaySoundFile(soundFilePaths[33])
                SendChatMessage("{square} [P3] Cash-Out for " .. player3CashOutAmount .. "G.", "RAID")
            else
                print("Please target (click on) the Dealer and try again!")
            end
            editBox:SetText("")
        end)
     
    else
        print("You don't have that much in your bankroll. Please choose a lower amount.")
    end

end
-- Player 4 Buy-In Function
function player4BuyIn()
    player4BuyInAmount = tonumber(buyInEditBox:GetText()) -- Get the entered bet amount
    if player4BuyInAmount and player4BuyInAmount >= minBetPP then
        
        buyInEditBox:SetFocus(false)
        buyInEditBox:ClearFocus()
        PlaySoundFile(soundFilePaths[33])
        
        player4BuyInAmountGoldValue = player4BuyInAmount * 10000

        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/trade", chatFrame)
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:Insert("/trade")
        ChatEdit_SendText(editBox)
        C_Timer.After(1, function()
            if TradeFrame:IsShown() then
                -- Set the copper amount in the trade window
                MoneyInputFrame_SetCopper(TradePlayerInputMoneyFrame, player4BuyInAmountGoldValue)
                
                -- Send the chat message only if the trade window is open
                SendChatMessage("{square} [P4] Buy-In for " .. player4BuyInAmount .. "G.", "RAID")
            else
                print("Please target (click on) the Dealer and try again!")
            end
            editBox:SetText("")
        end)
    else
        print("Please enter a value of at least 100G.")
    end

end
-- Player 4 Cash-Out Function
function player4CashOut()
    player4CashOutAmount = tonumber(cashOutEditBox:GetText()) -- Get the entered bet amount
    player4currentBankroll = tonumber(string.match(cashDeskFrame.player4TotalBankroll:GetText(), "%d+"))

    if player4CashOutAmount <= player4currentBankroll then

        cashOutEditBox:SetFocus(false)
        cashOutEditBox:ClearFocus()
        

        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/trade", chatFrame)
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:Insert("/trade")
        ChatEdit_SendText(editBox)

        C_Timer.After(1, function()
            if TradeFrame:IsShown() then
                PlaySoundFile(soundFilePaths[33])
                SendChatMessage("{square} [P4] Cash-Out for " .. player4CashOutAmount .. "G.", "RAID")
            else
                print("Please target (click on) the Dealer and try again!")
            end
            editBox:SetText("")
        end)
     
    else
        print("You don't have that much in your bankroll. Please choose a lower amount.")
    end

end
-- Player 5 Buy-In Function
function player5BuyIn()
    player5BuyInAmount = tonumber(buyInEditBox:GetText()) -- Get the entered bet amount
    if player5BuyInAmount and player5BuyInAmount >= minBetPP then
        
        buyInEditBox:SetFocus(false)
        buyInEditBox:ClearFocus()
        PlaySoundFile(soundFilePaths[33])
        
        player5BuyInAmountGoldValue = player5BuyInAmount * 10000

        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/trade", chatFrame)
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:Insert("/trade")
        ChatEdit_SendText(editBox)
        C_Timer.After(1, function()
            if TradeFrame:IsShown() then
                -- Set the copper amount in the trade window
                MoneyInputFrame_SetCopper(TradePlayerInputMoneyFrame, player5BuyInAmountGoldValue)
                
                -- Send the chat message only if the trade window is open
                SendChatMessage("{square} [P5] Buy-In for " .. player5BuyInAmount .. "G.", "RAID")
            else
                print("Please target (click on) the Dealer and try again!")
            end
            editBox:SetText("")
        end)
    else
        print("Please enter a value of at least 100G.")
    end

end
-- Player 5 Cash-Out Function
function player5CashOut()
    player5CashOutAmount = tonumber(cashOutEditBox:GetText()) -- Get the entered bet amount
    player5currentBankroll = tonumber(string.match(cashDeskFrame.player5TotalBankroll:GetText(), "%d+"))

    if player5CashOutAmount <= player5currentBankroll then

        cashOutEditBox:SetFocus(false)
        cashOutEditBox:ClearFocus()
        

        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/trade", chatFrame)
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:Insert("/trade")
        ChatEdit_SendText(editBox)

        C_Timer.After(1, function()
            if TradeFrame:IsShown() then
                PlaySoundFile(soundFilePaths[33])
                SendChatMessage("{square} [P5] Cash-Out for " .. player5CashOutAmount .. "G.", "RAID")
            else
                print("Please target (click on) the Dealer and try again!")
            end
            editBox:SetText("")
        end)
     
    else
        print("You don't have that much in your bankroll. Please choose a lower amount.")
    end

end

-- Buy-In Instructions Frame
stepsFrame = CreateFrame("Frame", "BlackjackStepsFrame", UIParent, "BasicFrameTemplate")
stepsFrame:SetSize(300, 250)
stepsFrame:SetPoint("LEFT", cashDeskFrame, 5, 40)
stepsFrame:SetFrameStrata("TOOLTIP")
stepsFrame:SetFrameLevel(tableLimitsFrame:GetFrameLevel() + 11)
stepsFrame:Hide()

stepsFrame.title = stepsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame.title:SetPoint("TOP", stepsFrame, 0, -5)
stepsFrame.title:SetText("Buy-In Instructions")

stepsFrame.dealerImage = stepsFrame:CreateTexture(nil, "OVERLAY")
stepsFrame.dealerImage:SetSize(256, 128)
stepsFrame.dealerImage:SetPoint("CENTER", stepsFrame, 0, 13)
if currentRealm == "Earthshaker" then
    stepsFrame.dealerImage:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\DealerTargetEarthshaker.tga")
elseif currentRealm == "Gehennas" then
    stepsFrame.dealerImage:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\DealerTargetGehennas.tga")
else
    stepsFrame.dealerImage:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\DealerTarget.tga")
end
stepsFrame.dealerImage:SetBlendMode("BLEND")
stepsFrame.dealerImage:SetDrawLayer("ARTWORK")

stepsFrame.step1Title = stepsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame.step1Title:SetPoint("CENTER", stepsFrame, 0, 83)
stepsFrame.step1Title:SetText("STEP 1")
stepsFrame.step1Title:SetJustifyH("CENTER")
stepsFrame.step1Title:SetTextColor(1, 0.298, 0.298)
stepsFrame.step1Title:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")

stepsFrame.step1Text = stepsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame.step1Text:SetPoint("CENTER", stepsFrame, 0, 67)
stepsFrame.step1Text:SetText("Target the Dealer")
stepsFrame.step1Text:SetJustifyH("CENTER")
stepsFrame.step1Text:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

stepsFrame.step2Title = stepsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame.step2Title:SetPoint("CENTER", stepsFrame, 0, -35)
stepsFrame.step2Title:SetText("STEP 2")
stepsFrame.step2Title:SetJustifyH("CENTER")
stepsFrame.step2Title:SetTextColor(1, 0.298, 0.298)
stepsFrame.step2Title:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")

stepsFrame.step2Text = stepsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame.step2Text:SetPoint("CENTER", stepsFrame, 0, -51)
stepsFrame.step2Text:SetText("Type in an amount (100G minimum)")
stepsFrame.step2Text:SetJustifyH("CENTER")
stepsFrame.step2Text:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

stepsFrame.step3Title = stepsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame.step3Title:SetPoint("CENTER", stepsFrame, 0, -84)
stepsFrame.step3Title:SetText("STEP 3")
stepsFrame.step3Title:SetJustifyH("CENTER")
stepsFrame.step3Title:SetTextColor(1, 0.298, 0.298)
stepsFrame.step3Title:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")

stepsFrame.step3Text = stepsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame.step3Text:SetPoint("CENTER", stepsFrame, 0, -100)
stepsFrame.step3Text:SetText("Press the 'Buy-In' button")
stepsFrame.step3Text:SetJustifyH("CENTER")
stepsFrame.step3Text:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Cash-Out Instructions Frame
stepsFrame2 = CreateFrame("Frame", "BlackjackStepsFrame", UIParent, "BasicFrameTemplate")
stepsFrame2:SetSize(300, 250)
stepsFrame2:SetPoint("RIGHT", cashDeskFrame, -5, 40)
stepsFrame2:SetFrameStrata("TOOLTIP")
stepsFrame2:SetFrameLevel(tableLimitsFrame:GetFrameLevel() + 11)
stepsFrame2:Hide()

stepsFrame2.title = stepsFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame2.title:SetPoint("TOP", stepsFrame2, 0, -5)
stepsFrame2.title:SetText("Cash-Out Instructions")

stepsFrame2.dealerImage2 = stepsFrame2:CreateTexture(nil, "OVERLAY")
stepsFrame2.dealerImage2:SetSize(256, 128)
stepsFrame2.dealerImage2:SetPoint("CENTER", stepsFrame2, 0, 13)
if currentRealm == "Earthshaker" then
    stepsFrame2.dealerImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\DealerTargetEarthshaker.tga")
elseif currentRealm == "Gehennas" then
    stepsFrame2.dealerImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\DealerTargetGehennas.tga")
else
    stepsFrame2.dealerImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\DealerTarget.tga")
end
stepsFrame2.dealerImage2:SetBlendMode("BLEND")
stepsFrame2.dealerImage2:SetDrawLayer("ARTWORK")

stepsFrame2.step1Title2 = stepsFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame2.step1Title2:SetPoint("CENTER", stepsFrame2, 0, 83)
stepsFrame2.step1Title2:SetText("STEP 1")
stepsFrame2.step1Title2:SetJustifyH("CENTER")
stepsFrame2.step1Title2:SetTextColor(1, 0.298, 0.298)
stepsFrame2.step1Title2:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")

stepsFrame2.step1Text2 = stepsFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame2.step1Text2:SetPoint("CENTER", stepsFrame2, 0, 67)
stepsFrame2.step1Text2:SetText("Target the Dealer")
stepsFrame2.step1Text2:SetJustifyH("CENTER")
stepsFrame2.step1Text2:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

stepsFrame2.step2Title2 = stepsFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame2.step2Title2:SetPoint("CENTER", stepsFrame2, 0, -35)
stepsFrame2.step2Title2:SetText("STEP 2")
stepsFrame2.step2Title2:SetJustifyH("CENTER")
stepsFrame2.step2Title2:SetTextColor(1, 0.298, 0.298)
stepsFrame2.step2Title2:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")

stepsFrame2.step2Text2 = stepsFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame2.step2Text2:SetPoint("CENTER", stepsFrame2, 0, -51)
stepsFrame2.step2Text2:SetText("Type in any amount (within your bankroll)")
stepsFrame2.step2Text2:SetJustifyH("CENTER")
stepsFrame2.step2Text2:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

stepsFrame2.step3Title2 = stepsFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame2.step3Title2:SetPoint("CENTER", stepsFrame2, 0, -84)
stepsFrame2.step3Title2:SetText("STEP 3")
stepsFrame2.step3Title2:SetJustifyH("CENTER")
stepsFrame2.step3Title2:SetTextColor(1, 0.298, 0.298)
stepsFrame2.step3Title2:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")

stepsFrame2.step3Text2 = stepsFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
stepsFrame2.step3Text2:SetPoint("CENTER", stepsFrame2, 0, -100)
stepsFrame2.step3Text2:SetText("Press the 'Cash-Out' button")
stepsFrame2.step3Text2:SetJustifyH("CENTER")
stepsFrame2.step3Text2:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

cashDeskFrame:SetScript("OnHide", function(self)
    stepsFrame:Hide()
    stepsFrame2:Hide()
end)

cashDeskFrame:SetScript("OnMouseDown", function(self, button)
    if button == "LeftButton" then
        buyInEditBox:ClearFocus()
        cashOutEditBox:ClearFocus()
    end
end)

stepsFrame:SetScript("OnMouseDown", function(self, button)
    if button == "LeftButton" then
        buyInEditBox:ClearFocus()
        cashOutEditBox:ClearFocus()
    end
end)

stepsFrame2:SetScript("OnMouseDown", function(self, button)
    if button == "LeftButton" then
        buyInEditBox:ClearFocus()
        cashOutEditBox:ClearFocus()
    end
end)


















-- >> LAUNCH FRAME <<
-- >> LAUNCH FRAME <<
-- >> LAUNCH FRAME <<

-- Create a frame for the test screen
launchFrame = CreateFrame("Frame", "BlackjackLaunchFrame", UIParent, "BasicFrameTemplateWithInset")
launchFrame:SetSize(640, 475)
launchFrame:SetPoint("CENTER")
launchFrame:SetFrameStrata("HIGH")
launchFrame:SetFrameLevel(launchFrame:GetFrameLevel() + 100)
launchFrame:Hide()

-- Add a title to the test frame
launchFrame.title = launchFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
launchFrame.title:SetPoint("TOP", launchFrame, 0, -5)
launchFrame.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

launchFrame.background = launchFrame:CreateTexture(nil, "OVERLAY")
launchFrame.background:SetSize(1364, 682)
launchFrame.background:SetPoint("CENTER", launchFrame, 22, 2)
launchFrame.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\newUI.tga")
launchFrame.background:SetBlendMode("BLEND")
launchFrame.background:SetDrawLayer("ARTWORK")

launchFrame.selectRoleButton = CreateFrame("Button", nil, launchFrame, "GameMenuButtonTemplate")
launchFrame.selectRoleButton:SetPoint("CENTER", launchFrame, 0, -75)
launchFrame.selectRoleButton:SetSize(140, 35)
launchFrame.selectRoleButton:SetText("Select Your Role")

launchFrame.selectButtonPlayer = CreateFrame("Button", nil, launchFrame, "GameMenuButtonTemplate")
launchFrame.selectButtonPlayer:SetPoint("RIGHT", launchFrame, -110, 117)
launchFrame.selectButtonPlayer:SetSize(70, 25)
launchFrame.selectButtonPlayer:SetText("Select")
launchFrame.selectButtonPlayer:SetNormalFontObject("GameFontWhiteSmall")
launchFrame.selectButtonPlayer:SetHighlightFontObject("GameFontWhiteSmall")
launchFrame.selectButtonPlayer:Hide()

launchFrame.selectButtonDealer = CreateFrame("Button", nil, launchFrame, "GameMenuButtonTemplate")
launchFrame.selectButtonDealer:SetPoint("RIGHT", launchFrame, -189, -137)
launchFrame.selectButtonDealer:SetSize(70, 25)
launchFrame.selectButtonDealer:SetText("Select")
launchFrame.selectButtonDealer:SetNormalFontObject("GameFontWhiteSmall")
launchFrame.selectButtonDealer:SetHighlightFontObject("GameFontWhiteSmall")
launchFrame.selectButtonDealer:Hide()

launchFrame.goBackButton = CreateFrame("Button", nil, launchFrame, "GameMenuButtonTemplate")
launchFrame.goBackButton:SetPoint("TOPLEFT", launchFrame, 15, -35)
launchFrame.goBackButton:SetSize(70, 25)
launchFrame.goBackButton:SetText("Return")
launchFrame.goBackButton:SetNormalFontObject("GameFontWhiteSmall")
launchFrame.goBackButton:SetHighlightFontObject("GameFontWhiteSmall")
launchFrame.goBackButton:Hide()

-- Enable click-and-drag functionality
launchFrame:SetMovable(true)
launchFrame:EnableMouse(true)
launchFrame:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
launchFrame:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

launchFrame:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)

-- Create a frame for the test screen
dealerDeniedFrame = CreateFrame("Frame", "BlackjackdealerDeniedFrame", launchFrame, "TranslucentFrameTemplate")
dealerDeniedFrame:SetSize(400, 125)
dealerDeniedFrame:SetPoint("CENTER")
dealerDeniedFrame:Hide()

dealerDeniedFrame.dealerStatus = dealerDeniedFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerDeniedFrame.dealerStatus:SetPoint("CENTER", dealerDeniedFrame, 0, 15)
dealerDeniedFrame.dealerStatus:SetText("You must be the leader of a raid group in order to\naccess this role. Please fix and try again.")
dealerDeniedFrame.dealerStatus:SetJustifyH("CENTER")
dealerDeniedFrame.dealerStatus:SetFont("Fonts\\FRIZQT__.TTF", 13, "OUTLINE")

dealerDeniedFrame.closeButton = CreateFrame("Button", nil, dealerDeniedFrame, "GameMenuButtonTemplate")
dealerDeniedFrame.closeButton:SetPoint("CENTER", dealerDeniedFrame, 0, -20)
dealerDeniedFrame.closeButton:SetSize(70, 25)
dealerDeniedFrame.closeButton:SetText("Close")
dealerDeniedFrame.closeButton:SetNormalFontObject("GameFontWhiteSmall")
dealerDeniedFrame.closeButton:SetHighlightFontObject("GameFontWhiteSmall")




-- Create a frame for the test screen
launchFrame2 = CreateFrame("Frame", "BlackjackLaunchFrame2", UIParent, "BasicFrameTemplateWithInset")
launchFrame2:SetSize(640, 475)
launchFrame2:SetPoint("CENTER")
launchFrame2:SetFrameStrata("HIGH")
launchFrame2:SetFrameLevel(launchFrame2:GetFrameLevel() + 100)
launchFrame2:Hide()

-- Add a title to the test frame
launchFrame2.title = launchFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
launchFrame2.title:SetPoint("TOP", launchFrame2, 0, -5)
launchFrame2.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

launchFrame2.background = launchFrame2:CreateTexture(nil, "OVERLAY")
launchFrame2.background:SetSize(1364, 682)
launchFrame2.background:SetPoint("CENTER", launchFrame2, 22, 2)
launchFrame2.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\newUI3.tga")
launchFrame2.background:SetBlendMode("BLEND")
launchFrame2.background:SetDrawLayer("ARTWORK")

launchFrame2.goBackButton2 = CreateFrame("Button", nil, launchFrame2, "GameMenuButtonTemplate")
launchFrame2.goBackButton2:SetPoint("TOPLEFT", launchFrame2, 15, -35)
launchFrame2.goBackButton2:SetSize(70, 25)
launchFrame2.goBackButton2:SetText("Return")
launchFrame2.goBackButton2:SetNormalFontObject("GameFontWhiteSmall")
launchFrame2.goBackButton2:SetHighlightFontObject("GameFontWhiteSmall")

launchFrame2.discordButton = CreateFrame("Button", nil, launchFrame2, "GameMenuButtonTemplate")
launchFrame2.discordButton:SetPoint("TOPRIGHT", launchFrame2, -15, -35)
launchFrame2.discordButton:SetSize(70, 25)
launchFrame2.discordButton:SetText("Discord")
launchFrame2.discordButton:SetNormalFontObject("GameFontWhiteSmall")
launchFrame2.discordButton:SetHighlightFontObject("GameFontWhiteSmall")

launchFrame2.discordButton:SetScript("OnClick", function()
    StaticPopupDialogs["DISCORD_LINK"] = {
        text = "Copy the link below to join our Discord:",
        button1 = "Close",
        hasEditBox = true,
        hasWideEditBox = true,
        editBoxWidth = 260,
        timeout = 0,
        whileDead = true,
        hideOnEscape = true,
        preferredIndex = STATICPOPUP_NUMDIALOGS,
    }

    dialog = StaticPopup_Show("DISCORD_LINK")
    dialog.editBox:SetText("https://discord.gg/mpzpBwpY2w")
    dialog.editBox:SetFocus()
    dialog.editBox:HighlightText()
end)

launchFrame2.tutorialButton = CreateFrame("Button", nil, launchFrame2, "GameMenuButtonTemplate")
launchFrame2.tutorialButton:SetPoint("TOPRIGHT", launchFrame2, -15, -158)
launchFrame2.tutorialButton:SetSize(70, 25)
launchFrame2.tutorialButton:SetText("Tutorial")
launchFrame2.tutorialButton:SetNormalFontObject("GameFontWhiteSmall")
launchFrame2.tutorialButton:SetHighlightFontObject("GameFontWhiteSmall")

launchFrame2.rulesButton = CreateFrame("Button", nil, launchFrame2, "GameMenuButtonTemplate")
launchFrame2.rulesButton:SetPoint("TOPRIGHT", launchFrame2, -15, -183)
launchFrame2.rulesButton:SetSize(70, 25)
launchFrame2.rulesButton:SetText("Rules")
launchFrame2.rulesButton:SetNormalFontObject("GameFontWhiteSmall")
launchFrame2.rulesButton:SetHighlightFontObject("GameFontWhiteSmall")

launchFrame2.faqsButton = CreateFrame("Button", nil, launchFrame2, "GameMenuButtonTemplate")
launchFrame2.faqsButton:SetPoint("TOPRIGHT", launchFrame2, -15, -208)
launchFrame2.faqsButton:SetSize(70, 25)
launchFrame2.faqsButton:SetText("FAQs")
launchFrame2.faqsButton:SetNormalFontObject("GameFontWhiteSmall")
launchFrame2.faqsButton:SetHighlightFontObject("GameFontWhiteSmall")

launchFrame2.join1Text = launchFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
launchFrame2.join1Text:SetPoint("CENTER", launchFrame2, 10, -72)
launchFrame2.join1Text:SetText("")
launchFrame2.join1Text:SetJustifyH("CENTER")
launchFrame2.join1Text:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
launchFrame2.join1Text:SetTextColor(0, 1, 0)

launchFrame2.dealerStatus = launchFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
launchFrame2.dealerStatus:SetPoint("BOTTOMLEFT", launchFrame2, 25, 39)
launchFrame2.dealerStatus:SetText("Dealer: N/A")
launchFrame2.dealerStatus:SetJustifyH("LEFT")
launchFrame2.dealerStatus:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")

launchFrame2.tableStatus = launchFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
launchFrame2.tableStatus:SetPoint("BOTTOMLEFT", launchFrame2, 25, 18)
launchFrame2.tableStatus:SetText("Table: Closed")
launchFrame2.tableStatus:SetJustifyH("LEFT")
launchFrame2.tableStatus:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")

launchFrame2.joinButton = CreateFrame("Button", nil, launchFrame2, "GameMenuButtonTemplate")
launchFrame2.joinButton:SetPoint("CENTER", launchFrame2, 0, -208)
launchFrame2.joinButton:SetSize(135, 30)
launchFrame2.joinButton:SetText("Join Table")
launchFrame2.joinButton:Disable()

-- Enable click-and-drag functionality
launchFrame2:SetMovable(true)
launchFrame2:EnableMouse(true)
launchFrame2:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
launchFrame2:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

launchFrame2:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)





-- Create a frame for the test screen
launchFrame3 = CreateFrame("Frame", "BlackjacklaunchFrame3", UIParent, "BasicFrameTemplateWithInset")
launchFrame3:SetSize(640, 475)
launchFrame3:SetPoint("CENTER")
launchFrame3:SetFrameStrata("HIGH")
launchFrame3:SetFrameLevel(launchFrame3:GetFrameLevel() + 100)
launchFrame3:Hide()

-- Add a title to the test frame
launchFrame3.title = launchFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
launchFrame3.title:SetPoint("TOP", launchFrame3, 0, -5)
launchFrame3.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

launchFrame3.background = launchFrame3:CreateTexture(nil, "OVERLAY")
launchFrame3.background:SetSize(1364, 682)
launchFrame3.background:SetPoint("CENTER", launchFrame3, 22, 2)
launchFrame3.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\newUI4.tga")
launchFrame3.background:SetBlendMode("BLEND")
launchFrame3.background:SetDrawLayer("ARTWORK")

launchFrame3.goBackButton = CreateFrame("Button", nil, launchFrame3, "GameMenuButtonTemplate")
launchFrame3.goBackButton:SetPoint("TOPLEFT", launchFrame3, 15, -35)
launchFrame3.goBackButton:SetSize(70, 25)
launchFrame3.goBackButton:SetText("Return")
launchFrame3.goBackButton:SetNormalFontObject("GameFontWhiteSmall")
launchFrame3.goBackButton:SetHighlightFontObject("GameFontWhiteSmall")

launchFrame3.discordButton = CreateFrame("Button", nil, launchFrame3, "GameMenuButtonTemplate")
launchFrame3.discordButton:SetPoint("TOPRIGHT", launchFrame3, -15, -35)
launchFrame3.discordButton:SetSize(70, 25)
launchFrame3.discordButton:SetText("Discord")
launchFrame3.discordButton:SetNormalFontObject("GameFontWhiteSmall")
launchFrame3.discordButton:SetHighlightFontObject("GameFontWhiteSmall")

launchFrame3.discordButton:SetScript("OnClick", function()
    StaticPopupDialogs["DISCORD_LINK"] = {
        text = "Copy the link below to join our Discord:",
        button1 = "Close",
        hasEditBox = true,
        hasWideEditBox = true,
        editBoxWidth = 260,
        timeout = 0,
        whileDead = true,
        hideOnEscape = true,
        preferredIndex = STATICPOPUP_NUMDIALOGS,
    }

    dialog = StaticPopup_Show("DISCORD_LINK")
    dialog.editBox:SetText("https://discord.gg/mpzpBwpY2w")
    dialog.editBox:SetFocus()
    dialog.editBox:HighlightText()
end)

launchFrame3.tutorialButton = CreateFrame("Button", nil, launchFrame3, "GameMenuButtonTemplate")
launchFrame3.tutorialButton:SetPoint("TOPRIGHT", launchFrame3, -15, -158)
launchFrame3.tutorialButton:SetSize(70, 25)
launchFrame3.tutorialButton:SetText("Tutorial")
launchFrame3.tutorialButton:SetNormalFontObject("GameFontWhiteSmall")
launchFrame3.tutorialButton:SetHighlightFontObject("GameFontWhiteSmall")

launchFrame3.rulesButton = CreateFrame("Button", nil, launchFrame3, "GameMenuButtonTemplate")
launchFrame3.rulesButton:SetPoint("TOPRIGHT", launchFrame3, -15, -183)
launchFrame3.rulesButton:SetSize(70, 25)
launchFrame3.rulesButton:SetText("Rules")
launchFrame3.rulesButton:SetNormalFontObject("GameFontWhiteSmall")
launchFrame3.rulesButton:SetHighlightFontObject("GameFontWhiteSmall")

launchFrame3.faqsButton = CreateFrame("Button", nil, launchFrame3, "GameMenuButtonTemplate")
launchFrame3.faqsButton:SetPoint("TOPRIGHT", launchFrame3, -15, -208)
launchFrame3.faqsButton:SetSize(70, 25)
launchFrame3.faqsButton:SetText("FAQs")
launchFrame3.faqsButton:SetNormalFontObject("GameFontWhiteSmall")
launchFrame3.faqsButton:SetHighlightFontObject("GameFontWhiteSmall")

launchFrame3.join1Text = launchFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
launchFrame3.join1Text:SetPoint("CENTER", launchFrame3, 10, -72)
launchFrame3.join1Text:SetText("")
launchFrame3.join1Text:SetJustifyH("CENTER")
launchFrame3.join1Text:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
launchFrame3.join1Text:SetTextColor(0, 1, 0)

launchFrame3.dealerStatus = launchFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
launchFrame3.dealerStatus:SetPoint("BOTTOMLEFT", launchFrame3, 25, 39)
launchFrame3.dealerStatus:SetText("Dealer: N/A")
launchFrame3.dealerStatus:SetJustifyH("LEFT")
launchFrame3.dealerStatus:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")

launchFrame3.tableStatus = launchFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
launchFrame3.tableStatus:SetPoint("BOTTOMLEFT", launchFrame3, 25, 18)
launchFrame3.tableStatus:SetText("Table: Closed")
launchFrame3.tableStatus:SetJustifyH("LEFT")
launchFrame3.tableStatus:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")

launchFrame3.openTableButton = CreateFrame("Button", nil, launchFrame3, "GameMenuButtonTemplate")
launchFrame3.openTableButton:SetPoint("CENTER", launchFrame3, 0, -208)
launchFrame3.openTableButton:SetSize(135, 30)
launchFrame3.openTableButton:SetText("Open Table")

-- Enable click-and-drag functionality
launchFrame3:SetMovable(true)
launchFrame3:EnableMouse(true)
launchFrame3:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
launchFrame3:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

launchFrame3:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)


-- Create a frame for the test screen
dealerStepsCheckFrame = CreateFrame("Frame", "BlackjackdealerStepsCheckFrame", launchFrame3, "TranslucentFrameTemplate")
dealerStepsCheckFrame:SetSize(445, 365)
dealerStepsCheckFrame:SetPoint("CENTER")
dealerStepsCheckFrame:SetFrameStrata("HIGH")
dealerStepsCheckFrame:SetFrameLevel(dealerStepsCheckFrame:GetFrameLevel() + 100)
dealerStepsCheckFrame:Hide()

dealerStepsCheckFrame.importantTitle = dealerStepsCheckFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerStepsCheckFrame.importantTitle:SetPoint("TOP", dealerStepsCheckFrame, 0, -25)
dealerStepsCheckFrame.importantTitle:SetText("IMPORTANT")
dealerStepsCheckFrame.importantTitle:SetJustifyH("CENTER")
dealerStepsCheckFrame.importantTitle:SetFont("Fonts\\FRIZQT__.TTF", 24, "OUTLINE")
dealerStepsCheckFrame.importantTitle:SetTextColor(1, 0.494, 0.494)

dealerStepsCheckFrame.importantTitle2 = dealerStepsCheckFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerStepsCheckFrame.importantTitle2:SetPoint("TOP", dealerStepsCheckFrame, 0, -50)
dealerStepsCheckFrame.importantTitle2:SetText("--  PLEASE READ BEFORE HOSTING  --")
dealerStepsCheckFrame.importantTitle2:SetJustifyH("CENTER")
dealerStepsCheckFrame.importantTitle2:SetFont("Fonts\\FRIZQT__.TTF", 11, "OUTLINE")
dealerStepsCheckFrame.importantTitle2:SetTextColor(1, 0.494, 0.494)

dealerStepsCheckFrame.step1 = dealerStepsCheckFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerStepsCheckFrame.step1:SetPoint("TOPLEFT", dealerStepsCheckFrame, 20, -80)
dealerStepsCheckFrame.step1:SetText("1. If this is your first time hosting, please click on the 'Tutorial' button\n    on the right and familiarise yourself with what to do. For any further\n    assistance, join our Discord and ask the community (or developers)\n    directly")
dealerStepsCheckFrame.step1:SetJustifyH("LEFT")
dealerStepsCheckFrame.step1:SetFont("Fonts\\FRIZQT__.TTF", 11, "OUTLINE")

dealerStepsCheckFrame.step2 = dealerStepsCheckFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerStepsCheckFrame.step2:SetPoint("TOPLEFT", dealerStepsCheckFrame, 20, -140)
dealerStepsCheckFrame.step2:SetText("2. This AddOn can be played WITHOUT using gold - simply credit a\n    bankroll without trading the Player. If you do plan on playing with real\n    gold, make sure you can afford to host. It's recommended to have\n    at least 50x the maximum main bet table limit.")
dealerStepsCheckFrame.step2:SetJustifyH("LEFT")
dealerStepsCheckFrame.step2:SetFont("Fonts\\FRIZQT__.TTF", 11, "OUTLINE")

dealerStepsCheckFrame.step3 = dealerStepsCheckFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerStepsCheckFrame.step3:SetPoint("TOPLEFT", dealerStepsCheckFrame, 20, -200)
dealerStepsCheckFrame.step3:SetText("3. If you encounter any technical issues, please report them in our\n    Discord server with a screenshot (if applicable) and a detailed\n    description as to what happened vs. what should have happened.")
dealerStepsCheckFrame.step3:SetJustifyH("LEFT")
dealerStepsCheckFrame.step3:SetFont("Fonts\\FRIZQT__.TTF", 11, "OUTLINE")

dealerStepsCheckFrame.step4 = dealerStepsCheckFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerStepsCheckFrame.step4:SetPoint("TOPLEFT", dealerStepsCheckFrame, 20, -250)
dealerStepsCheckFrame.step4:SetText("4. If playing with real gold, make sure you trade if a player chooses\n    to withdraw their funds. This will help build your reputation as a\n    dealer.")
dealerStepsCheckFrame.step4:SetJustifyH("LEFT")
dealerStepsCheckFrame.step4:SetFont("Fonts\\FRIZQT__.TTF", 11, "OUTLINE")

dealerStepsCheckFrame.checkBox = CreateFrame("CheckButton", nil, dealerStepsCheckFrame, "ChatConfigCheckButtonTemplate")
dealerStepsCheckFrame.checkBox:SetPoint("BOTTOM", dealerStepsCheckFrame, -120, 50)
dealerStepsCheckFrame.checkBox.Text:SetText("  I have read and agree to the above")

dealerStepsCheckFrame.continueButton = CreateFrame("Button", nil, dealerStepsCheckFrame, "GameMenuButtonTemplate")
dealerStepsCheckFrame.continueButton:SetPoint("BOTTOM", dealerStepsCheckFrame, 0, 20)
dealerStepsCheckFrame.continueButton:SetSize(90, 30)
dealerStepsCheckFrame.continueButton:SetText("Continue")
dealerStepsCheckFrame.continueButton:Disable()

-- Function to handle checkbox state change
local function CheckBox_OnClick(self)
    if self:GetChecked() then
        dealerStepsCheckFrame.continueButton:Enable()
        termsAgreed = true
    else
        dealerStepsCheckFrame.continueButton:Disable()
    end
end

-- Set the script for the checkbox
dealerStepsCheckFrame.checkBox:SetScript("OnClick", CheckBox_OnClick)




-- Create a frame for the test screen
tutorialFrame = CreateFrame("Frame", "BlackjackTutorialFrame", UIParent, "BasicFrameTemplateWithInset")
tutorialFrame:SetSize(640, 475)
tutorialFrame:SetPoint("CENTER")
tutorialFrame:SetFrameStrata("HIGH")
tutorialFrame:SetFrameLevel(tutorialFrame:GetFrameLevel() + 100)
tutorialFrame:Hide()

-- Add a title to the test frame
tutorialFrame.title = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.title:SetPoint("TOP", tutorialFrame, 0, -5)
tutorialFrame.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

tutorialFrame.background = tutorialFrame:CreateTexture(nil, "OVERLAY")
tutorialFrame.background:SetSize(1364, 682)
tutorialFrame.background:SetPoint("CENTER", tutorialFrame, 23, 2)
tutorialFrame.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Tutorial.tga")
tutorialFrame.background:SetBlendMode("BLEND")
tutorialFrame.background:SetDrawLayer("ARTWORK")

tutorialFrame.returnButton = CreateFrame("Button", nil, tutorialFrame, "GameMenuButtonTemplate")
tutorialFrame.returnButton:SetPoint("TOPLEFT", tutorialFrame, 15, -35)
tutorialFrame.returnButton:SetSize(70, 25)
tutorialFrame.returnButton:SetText("Return")
tutorialFrame.returnButton:SetNormalFontObject("GameFontWhiteSmall")
tutorialFrame.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

tutorialFrame.playerButton = CreateFrame("Button", nil, tutorialFrame, "GameMenuButtonTemplate")
tutorialFrame.playerButton:SetPoint("TOP", tutorialFrame, -50, -110)
tutorialFrame.playerButton:SetSize(90, 30)
tutorialFrame.playerButton:SetText("Player")
tutorialFrame.playerButton:Disable()

tutorialFrame.dealerButton = CreateFrame("Button", nil, tutorialFrame, "GameMenuButtonTemplate")
tutorialFrame.dealerButton:SetPoint("TOP", tutorialFrame, 50, -110)
tutorialFrame.dealerButton:SetSize(90, 30)
tutorialFrame.dealerButton:SetText("Dealer")

tutorialFrame.step1 = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step1:SetPoint("TOPLEFT", tutorialFrame, 110, -155)
tutorialFrame.step1:SetText("1. Join a raid group with the host (Dealer)")
tutorialFrame.step1:SetJustifyH("LEFT")
tutorialFrame.step1:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame.step1:SetTextColor(1, 0.882, 0.596)

tutorialFrame.step1a = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step1a:SetPoint("TOPLEFT", tutorialFrame, 120, -175)
tutorialFrame.step1a:SetText("• Ensure you are NOT the raid leader if you plan on joining as a Player")
tutorialFrame.step1a:SetJustifyH("LEFT")
tutorialFrame.step1a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrame.step2 = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step2:SetPoint("TOPLEFT", tutorialFrame, 110, -195)
tutorialFrame.step2:SetText("2. Politely ask the Dealer to open up the table for you")
tutorialFrame.step2:SetJustifyH("LEFT")
tutorialFrame.step2:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame.step2:SetTextColor(1, 0.882, 0.596)

tutorialFrame.step2a = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step2a:SetPoint("TOPLEFT", tutorialFrame, 120, -215)
tutorialFrame.step2a:SetText("• The table will need to be opened even if there is already an active table")
tutorialFrame.step2a:SetJustifyH("LEFT")
tutorialFrame.step2a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrame.step3 = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step3:SetPoint("TOPLEFT", tutorialFrame, 110, -235)
tutorialFrame.step3:SetText("3. Click the 'Join Table' button and choose an available seat")
tutorialFrame.step3:SetJustifyH("LEFT")
tutorialFrame.step3:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame.step3:SetTextColor(1, 0.882, 0.596)

tutorialFrame.step3a = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step3a:SetPoint("TOPLEFT", tutorialFrame, 120, -255)
tutorialFrame.step3a:SetText("• If the table is full you can still observe as a spectator until one becomes free")
tutorialFrame.step3a:SetJustifyH("LEFT")
tutorialFrame.step3a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrame.step4 = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step4:SetPoint("TOPLEFT", tutorialFrame, 110, -275)
tutorialFrame.step4:SetText("4. Click the 'Cash Desk' button in the bottom-left corner")
tutorialFrame.step4:SetJustifyH("LEFT")
tutorialFrame.step4:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame.step4:SetTextColor(1, 0.882, 0.596)

tutorialFrame.step4a = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step4a:SetPoint("TOPLEFT", tutorialFrame, 120, -295)
tutorialFrame.step4a:SetText("• This is where you will complete any deposit/withdrawal of funds to play with\n• Deposits and withdrawals should only take place between rounds")
tutorialFrame.step4a:SetJustifyH("LEFT")
tutorialFrame.step4a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrame.step5 = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step5:SetPoint("TOPLEFT", tutorialFrame, 110, -325)
tutorialFrame.step5:SetText("5. Return to the table and place a bet using the 'Bet' buttons")
tutorialFrame.step5:SetJustifyH("LEFT")
tutorialFrame.step5:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame.step5:SetTextColor(1, 0.882, 0.596)

tutorialFrame.step5a = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step5a:SetPoint("TOPLEFT", tutorialFrame, 120, -345)
tutorialFrame.step5a:SetText("• Placing a 'Main Bet' is mandatory but side bets are entirely optional\n• Ensure your bets are within the defined table limits set by the Dealer")
tutorialFrame.step5a:SetJustifyH("LEFT")
tutorialFrame.step5a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrame.step6 = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step6:SetPoint("TOPLEFT", tutorialFrame, 110, -375)
tutorialFrame.step6:SetText("6. Play the game!")
tutorialFrame.step6:SetJustifyH("LEFT")
tutorialFrame.step6:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame.step6:SetTextColor(1, 0.882, 0.596)

tutorialFrame.step6a = tutorialFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame.step6a:SetPoint("TOPLEFT", tutorialFrame, 120, -395)
tutorialFrame.step6a:SetText("• Once the round has started, you will be asked to make decisions on your turn\n• Refer to the 'Rules' page on the previous screen to learn how to play")
tutorialFrame.step6a:SetJustifyH("LEFT")
tutorialFrame.step6a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Enable click-and-drag functionality
tutorialFrame:SetMovable(true)
tutorialFrame:EnableMouse(true)
tutorialFrame:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
tutorialFrame:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

tutorialFrame:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)


-- Create a frame for the test screen
tutorialFrame2 = CreateFrame("Frame", "BlackjacktutorialFrame2", UIParent, "BasicFrameTemplateWithInset")
tutorialFrame2:SetSize(640, 475)
tutorialFrame2:SetPoint("CENTER")
tutorialFrame2:SetFrameStrata("HIGH")
tutorialFrame2:SetFrameLevel(tutorialFrame2:GetFrameLevel() + 100)
tutorialFrame2:Hide()

-- Add a title to the test frame
tutorialFrame2.title = tutorialFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame2.title:SetPoint("TOP", tutorialFrame2, 0, -5)
tutorialFrame2.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

tutorialFrame2.background = tutorialFrame2:CreateTexture(nil, "OVERLAY")
tutorialFrame2.background:SetSize(1364, 682)
tutorialFrame2.background:SetPoint("CENTER", tutorialFrame2, 23, 2)
tutorialFrame2.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Tutorial2.tga")
tutorialFrame2.background:SetBlendMode("BLEND")
tutorialFrame2.background:SetDrawLayer("ARTWORK")

tutorialFrame2.returnButton = CreateFrame("Button", nil, tutorialFrame2, "GameMenuButtonTemplate")
tutorialFrame2.returnButton:SetPoint("TOPLEFT", tutorialFrame2, 15, -35)
tutorialFrame2.returnButton:SetSize(70, 25)
tutorialFrame2.returnButton:SetText("Return")
tutorialFrame2.returnButton:SetNormalFontObject("GameFontWhiteSmall")
tutorialFrame2.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

tutorialFrame2.playerButton = CreateFrame("Button", nil, tutorialFrame2, "GameMenuButtonTemplate")
tutorialFrame2.playerButton:SetPoint("TOP", tutorialFrame2, -50, -110)
tutorialFrame2.playerButton:SetSize(90, 30)
tutorialFrame2.playerButton:SetText("Player")

tutorialFrame2.dealerButton = CreateFrame("Button", nil, tutorialFrame2, "GameMenuButtonTemplate")
tutorialFrame2.dealerButton:SetPoint("TOP", tutorialFrame2, 50, -110)
tutorialFrame2.dealerButton:SetSize(90, 30)
tutorialFrame2.dealerButton:SetText("Dealer")
tutorialFrame2.dealerButton:Disable()

tutorialFrame2.step1 = tutorialFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame2.step1:SetPoint("TOPLEFT", tutorialFrame2, 110, -155)
tutorialFrame2.step1:SetText("1. Invite a Player (or Player's) to a raid group")
tutorialFrame2.step1:SetJustifyH("LEFT")
tutorialFrame2.step1:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame2.step1:SetTextColor(1, 0.882, 0.596)

tutorialFrame2.step1a = tutorialFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame2.step1a:SetPoint("TOPLEFT", tutorialFrame2, 120, -175)
tutorialFrame2.step1a:SetText("• Ensure you ARE the raid leader before selecting the 'DEALER' option")
tutorialFrame2.step1a:SetJustifyH("LEFT")
tutorialFrame2.step1a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrame2.step2 = tutorialFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame2.step2:SetPoint("TOPLEFT", tutorialFrame2, 110, -195)
tutorialFrame2.step2:SetText("2. Click the 'Open Table' button on the Dealer UI")
tutorialFrame2.step2:SetJustifyH("LEFT")
tutorialFrame2.step2:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame2.step2:SetTextColor(1, 0.882, 0.596)

tutorialFrame2.step2a = tutorialFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame2.step2a:SetPoint("TOPLEFT", tutorialFrame2, 120, -215)
tutorialFrame2.step2a:SetText("• This will enable the 'Join Table' button for Player's\n\n• IMPORTANT  -  If you have an active table and want to invite a new Player,\n                            make sure that the table is clear and nobody places a bet\n                            before they have joined the raid group. This has been known\n                            to cause issues and crash the AddOn")
tutorialFrame2.step2a:SetJustifyH("LEFT")
tutorialFrame2.step2a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrame2.step3 = tutorialFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame2.step3:SetPoint("TOPLEFT", tutorialFrame2, 110, -285)
tutorialFrame2.step3:SetText("3. Update Player bankrolls using the '+' and '-' buttons")
tutorialFrame2.step3:SetJustifyH("LEFT")
tutorialFrame2.step3:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame2.step3:SetTextColor(1, 0.882, 0.596)

tutorialFrame2.step3a = tutorialFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame2.step3a:SetPoint("TOPLEFT", tutorialFrame2, 120, -305)
tutorialFrame2.step3a:SetText("• Whenever a Player visits the Cash Desk and wants to make a deposit or\nwithdrawal, remember to update the values accordingly on your banking tab")
tutorialFrame2.step3a:SetJustifyH("LEFT")
tutorialFrame2.step3a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrame2.step4 = tutorialFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame2.step4:SetPoint("TOPLEFT", tutorialFrame2, 110, -335)
tutorialFrame2.step4:SetText("4. Encourage Player's to place their bets in a timely manner")
tutorialFrame2.step4:SetJustifyH("LEFT")
tutorialFrame2.step4:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame2.step4:SetTextColor(1, 0.882, 0.596)

tutorialFrame2.step4a = tutorialFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame2.step4a:SetPoint("TOPLEFT", tutorialFrame2, 120, -355)
tutorialFrame2.step4a:SetText("• Once all bets have been placed you can start dealing the cards using the\n'Deal Cards' button at the bottom\n• Keep clicking 'Deal Cards' until every Player has two cards and you have one")
tutorialFrame2.step4a:SetJustifyH("LEFT")
tutorialFrame2.step4a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrame2.page1 = tutorialFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame2.page1:SetPoint("BOTTOM", tutorialFrame2, 0, 57)
tutorialFrame2.page1:SetText("PAGE 1")
tutorialFrame2.page1:SetJustifyH("CENTER")
tutorialFrame2.page1:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
tutorialFrame2.page1:SetTextColor(1, 0.882, 0.596)

tutorialFrame2.nextPageButton = CreateFrame("Button", nil, tutorialFrame2, "GameMenuButtonTemplate")
tutorialFrame2.nextPageButton:SetPoint("BOTTOMRIGHT", tutorialFrame2, -113, 53)
tutorialFrame2.nextPageButton:SetSize(110, 25)
tutorialFrame2.nextPageButton:SetText("Next Page >")
tutorialFrame2.nextPageButton:SetNormalFontObject("GameFontWhiteSmall")
tutorialFrame2.nextPageButton:SetHighlightFontObject("GameFontWhiteSmall")

-- Enable click-and-drag functionality
tutorialFrame2:SetMovable(true)
tutorialFrame2:EnableMouse(true)
tutorialFrame2:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
tutorialFrame2:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

tutorialFrame2:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)

-- Create a frame for the test screen
tutorialFrame3 = CreateFrame("Frame", "BlackjacktutorialFrame3", UIParent, "BasicFrameTemplateWithInset")
tutorialFrame3:SetSize(640, 475)
tutorialFrame3:SetPoint("CENTER")
tutorialFrame3:SetFrameStrata("HIGH")
tutorialFrame3:SetFrameLevel(tutorialFrame3:GetFrameLevel() + 100)
tutorialFrame3:Hide()

-- Add a title to the test frame
tutorialFrame3.title = tutorialFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame3.title:SetPoint("TOP", tutorialFrame3, 0, -5)
tutorialFrame3.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

tutorialFrame3.background = tutorialFrame3:CreateTexture(nil, "OVERLAY")
tutorialFrame3.background:SetSize(1364, 682)
tutorialFrame3.background:SetPoint("CENTER", tutorialFrame3, 23, 2)
tutorialFrame3.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Tutorial2.tga")
tutorialFrame3.background:SetBlendMode("BLEND")
tutorialFrame3.background:SetDrawLayer("ARTWORK")

tutorialFrame3.returnButton = CreateFrame("Button", nil, tutorialFrame3, "GameMenuButtonTemplate")
tutorialFrame3.returnButton:SetPoint("TOPLEFT", tutorialFrame3, 15, -35)
tutorialFrame3.returnButton:SetSize(70, 25)
tutorialFrame3.returnButton:SetText("Return")
tutorialFrame3.returnButton:SetNormalFontObject("GameFontWhiteSmall")
tutorialFrame3.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

tutorialFrame3.playerButton = CreateFrame("Button", nil, tutorialFrame3, "GameMenuButtonTemplate")
tutorialFrame3.playerButton:SetPoint("TOP", tutorialFrame3, -50, -110)
tutorialFrame3.playerButton:SetSize(90, 30)
tutorialFrame3.playerButton:SetText("Player")

tutorialFrame3.dealerButton = CreateFrame("Button", nil, tutorialFrame3, "GameMenuButtonTemplate")
tutorialFrame3.dealerButton:SetPoint("TOP", tutorialFrame3, 50, -110)
tutorialFrame3.dealerButton:SetSize(90, 30)
tutorialFrame3.dealerButton:SetText("Dealer")
tutorialFrame3.dealerButton:Disable()

tutorialFrame3.previousPageButton = CreateFrame("Button", nil, tutorialFrame3, "GameMenuButtonTemplate")
tutorialFrame3.previousPageButton:SetPoint("BOTTOMLEFT", tutorialFrame3, 113, 53)
tutorialFrame3.previousPageButton:SetSize(110, 25)
tutorialFrame3.previousPageButton:SetText("< Previous Page")
tutorialFrame3.previousPageButton:SetNormalFontObject("GameFontWhiteSmall")
tutorialFrame3.previousPageButton:SetHighlightFontObject("GameFontWhiteSmall")

tutorialFrame3.page1 = tutorialFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame3.page1:SetPoint("BOTTOM", tutorialFrame3, 0, 57)
tutorialFrame3.page1:SetText("PAGE 2")
tutorialFrame3.page1:SetJustifyH("CENTER")
tutorialFrame3.page1:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
tutorialFrame3.page1:SetTextColor(1, 0.882, 0.596)

tutorialFrame3.step5 = tutorialFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame3.step5:SetPoint("TOPLEFT", tutorialFrame3, 110, -155)
tutorialFrame3.step5:SetText("5. Observe the Player's decisions and react accordingly")
tutorialFrame3.step5:SetJustifyH("LEFT")
tutorialFrame3.step5:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame3.step5:SetTextColor(1, 0.882, 0.596)

tutorialFrame3.step5a = tutorialFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame3.step5a:SetPoint("TOPLEFT", tutorialFrame3, 120, -175)
tutorialFrame3.step5a:SetText("• Keep an eye on the chatbox to see what the Player's choose to do:\n\n          HIT  -  click the 'Deal Cards' button once\n          STAND  -  wait for the next Player's decision\n          DOUBLE  -  click the 'Deal Cards' button once\n          SPLIT  -  click the 'Deal Cards' button twice\n\n• Whenever its your turn (e.g. the last player has chosen STAND or DOUBLE) you\nmust keep hitting the 'Deal Cards' button until you have a total of at least 17")
tutorialFrame3.step5a:SetJustifyH("LEFT")
tutorialFrame3.step5a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrame3.step6 = tutorialFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame3.step6:SetPoint("TOPLEFT", tutorialFrame3, 110, -265)
tutorialFrame3.step6:SetText("6. Wait for the final result and then reset the table")
tutorialFrame3.step6:SetJustifyH("LEFT")
tutorialFrame3.step6:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame3.step6:SetTextColor(1, 0.882, 0.596)

tutorialFrame3.step6a = tutorialFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame3.step6a:SetPoint("TOPLEFT", tutorialFrame3, 120, -285)
tutorialFrame3.step6a:SetText("• Once you have a hand total of 17 or more, the results for each player will be\nannounced automatically over a period of 2-10 seconds\n• Bankroll totals will update for both the Dealer and Player's in real-time\n• Wait until this announcement has finished before starting a new round\n• Hit the 'New Game' button to reset and wipe the table clean")
tutorialFrame3.step6a:SetJustifyH("LEFT")
tutorialFrame3.step6a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrame3.step7 = tutorialFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame3.step7:SetPoint("TOPLEFT", tutorialFrame3, 110, -340)
tutorialFrame3.step7:SetText("7. Don't forget to shuffle!")
tutorialFrame3.step7:SetJustifyH("LEFT")
tutorialFrame3.step7:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrame3.step7:SetTextColor(1, 0.882, 0.596)

tutorialFrame3.step7a = tutorialFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrame3.step7a:SetPoint("TOPLEFT", tutorialFrame3, 120, -360)
tutorialFrame3.step7a:SetText("• Keep an eye on the '/roll' number in chat - this lowers as the game goes on\n• Hit the 'Shuffle Deck' button at the END of a round when the number gets\nlow - if you forget and it hits 1 then no more cards will be generated")
tutorialFrame3.step7a:SetJustifyH("LEFT")
tutorialFrame3.step7a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Enable click-and-drag functionality
tutorialFrame3:SetMovable(true)
tutorialFrame3:EnableMouse(true)
tutorialFrame3:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
tutorialFrame3:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

tutorialFrame3:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)





-- Create a frame for the test screen
faqsFrame = CreateFrame("Frame", "BlackjackFAQsFrame", UIParent, "BasicFrameTemplateWithInset")
faqsFrame:SetSize(640, 475)
faqsFrame:SetPoint("CENTER")
faqsFrame:SetFrameStrata("HIGH")
faqsFrame:SetFrameLevel(faqsFrame:GetFrameLevel() + 100)
faqsFrame:Hide()

-- Add a title to the test frame
faqsFrame.title = faqsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrame.title:SetPoint("TOP", faqsFrame, 0, -5)
faqsFrame.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

faqsFrame.background = faqsFrame:CreateTexture(nil, "OVERLAY")
faqsFrame.background:SetSize(1364, 682)
faqsFrame.background:SetPoint("CENTER", faqsFrame, 23, 2)
faqsFrame.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\FAQs.tga")
faqsFrame.background:SetBlendMode("BLEND")
faqsFrame.background:SetDrawLayer("ARTWORK")

faqsFrame.returnButton = CreateFrame("Button", nil, faqsFrame, "GameMenuButtonTemplate")
faqsFrame.returnButton:SetPoint("TOPLEFT", faqsFrame, 15, -35)
faqsFrame.returnButton:SetSize(70, 25)
faqsFrame.returnButton:SetText("Return")
faqsFrame.returnButton:SetNormalFontObject("GameFontWhiteSmall")
faqsFrame.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

faqsFrame.faq1 = faqsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrame.faq1:SetPoint("TOPLEFT", faqsFrame, 110, -110)
faqsFrame.faq1:SetText("1. Why was the Blackjack AddOn created in the first place?")
faqsFrame.faq1:SetJustifyH("LEFT")
faqsFrame.faq1:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
faqsFrame.faq1:SetTextColor(1, 0.882, 0.596)

faqsFrame.faq1a = faqsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrame.faq1a:SetPoint("TOPLEFT", faqsFrame, 120, -130)
faqsFrame.faq1a:SetText("It was developed to replace 'death-rolling' between friends, guild-mates or\nraid-party members, as a more fun (and immersive) alternative")
faqsFrame.faq1a:SetJustifyH("LEFT")
faqsFrame.faq1a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

faqsFrame.faq2 = faqsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrame.faq2:SetPoint("TOPLEFT", faqsFrame, 110, -160)
faqsFrame.faq2:SetText("2. How can I be sure the cards are generated (dealt on the table)\n    fairly and with 100% randomisation?")
faqsFrame.faq2:SetJustifyH("LEFT")
faqsFrame.faq2:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
faqsFrame.faq2:SetTextColor(1, 0.882, 0.596)

faqsFrame.faq2a = faqsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrame.faq2a:SetPoint("TOPLEFT", faqsFrame, 120, -190)
faqsFrame.faq2a:SetText("All cards are generated using the in-game WoW command '/roll' meaning that\nall Player's (and the Dealer) witness the result at the same time. For a more\ndetailed, technical explanation, please read the FAQs section on CurseForge")
faqsFrame.faq2a:SetJustifyH("LEFT")
faqsFrame.faq2a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

faqsFrame.faq3 = faqsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrame.faq3:SetPoint("TOPLEFT", faqsFrame, 110, -230)
faqsFrame.faq3:SetText("3. What is the likelihood that I win whilst playing with this\n    AddOn, and how do I know it's not totally rigged?")
faqsFrame.faq3:SetJustifyH("LEFT")
faqsFrame.faq3:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
faqsFrame.faq3:SetTextColor(1, 0.882, 0.596)

faqsFrame.faq3a = faqsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrame.faq3a:SetPoint("TOPLEFT", faqsFrame, 120, -260)
faqsFrame.faq3a:SetText("It's important to note that blackjack, like any casino game, comes with an\ninherent house edge (advantage). In blackjack, this house edge depends upon a\nnumber of factors, including but not limited to, the Player's ability to double\nsplit, and surrender; the Dealer standing on soft-17 (Ace + 6); the number of\ndecks used in the shoe; how often the deck is shuffled; and whether the player\nis following perfect 'Blackjack Strategy' - the chart for this can be found below")
faqsFrame.faq3a:SetJustifyH("LEFT")
faqsFrame.faq3a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

faqsFrame.chartButton = CreateFrame("Button", nil, faqsFrame, "GameMenuButtonTemplate")
faqsFrame.chartButton:SetPoint("TOPLEFT", faqsFrame, 119, -322)
faqsFrame.chartButton:SetSize(150, 25)
faqsFrame.chartButton:SetText("Blackjack Strategy Chart")
faqsFrame.chartButton:SetNormalFontObject("GameFontWhiteSmall")
faqsFrame.chartButton:SetHighlightFontObject("GameFontWhiteSmall")

faqsFrame.chartButton:SetScript("OnClick", function()
    StaticPopupDialogs["WEBSITE_LINK"] = {
        text = "Copy the link below into a web browser:",
        button1 = "Close",
        hasEditBox = true,
        hasWideEditBox = true,
        editBoxWidth = 260,
        timeout = 0,
        whileDead = true,
        hideOnEscape = true,
        preferredIndex = STATICPOPUP_NUMDIALOGS,
    }

    dialog = StaticPopup_Show("WEBSITE_LINK")
    dialog.editBox:SetText("https://www.blackjackapprenticeship.com/wp-content/uploads/2018/10/mini-blackjack-strategy-chart.png")
    dialog.editBox:SetFocus()
    dialog.editBox:HighlightText()
end)

faqsFrame.faq4 = faqsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrame.faq4:SetPoint("TOPLEFT", faqsFrame, 110, -355)
faqsFrame.faq4:SetText("4. How do I increase the table limits, or change the number of\n     decks in the shoe, if I'm hosting a table as the Dealer?")
faqsFrame.faq4:SetJustifyH("LEFT")
faqsFrame.faq4:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
faqsFrame.faq4:SetTextColor(1, 0.882, 0.596)

faqsFrame.faq4a = faqsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrame.faq4a:SetPoint("TOPLEFT", faqsFrame, 120, -385)
faqsFrame.faq4a:SetText("To be able to fully customise your table experience you must become a\n'Licensed Dealer' - this will grant you access to additional features and your\ncharacter will be displayed on the AddOn UI. Visit www.wowblackjack.com")
faqsFrame.faq4a:SetJustifyH("LEFT")
faqsFrame.faq4a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Enable click-and-drag functionality
faqsFrame:SetMovable(true)
faqsFrame:EnableMouse(true)
faqsFrame:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
faqsFrame:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

faqsFrame:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)






-- Create a frame for the test screen
rulesFrame2 = CreateFrame("Frame", "BlackjackRules2Frame", UIParent, "BasicFrameTemplateWithInset")
rulesFrame2:SetSize(640, 475)
rulesFrame2:SetPoint("CENTER")
rulesFrame2:SetFrameStrata("HIGH")
rulesFrame2:SetFrameLevel(rulesFrame2:GetFrameLevel() + 100)
rulesFrame2:Hide()

-- Add a title to the test frame
rulesFrame2.title = rulesFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2.title:SetPoint("TOP", rulesFrame2, 0, -5)
rulesFrame2.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

rulesFrame2.background = rulesFrame2:CreateTexture(nil, "OVERLAY")
rulesFrame2.background:SetSize(1364, 682)
rulesFrame2.background:SetPoint("CENTER", rulesFrame2, 23, 2)
rulesFrame2.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Rules.tga")
rulesFrame2.background:SetBlendMode("BLEND")
rulesFrame2.background:SetDrawLayer("ARTWORK")

rulesFrame2.returnButton = CreateFrame("Button", nil, rulesFrame2, "GameMenuButtonTemplate")
rulesFrame2.returnButton:SetPoint("TOPLEFT", rulesFrame2, 15, -35)
rulesFrame2.returnButton:SetSize(70, 25)
rulesFrame2.returnButton:SetText("Return")
rulesFrame2.returnButton:SetNormalFontObject("GameFontWhiteSmall")
rulesFrame2.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

rulesFrame2.nextPageButton = CreateFrame("Button", nil, rulesFrame2, "GameMenuButtonTemplate")
rulesFrame2.nextPageButton:SetPoint("BOTTOMRIGHT", rulesFrame2, -113, 53)
rulesFrame2.nextPageButton:SetSize(110, 25)
rulesFrame2.nextPageButton:SetText("Next Page >")
rulesFrame2.nextPageButton:SetNormalFontObject("GameFontWhiteSmall")
rulesFrame2.nextPageButton:SetHighlightFontObject("GameFontWhiteSmall")

rulesFrame2.step1 = rulesFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2.step1:SetPoint("TOPLEFT", rulesFrame2, 110, -110)
rulesFrame2.step1:SetText("1. Card Values")
rulesFrame2.step1:SetJustifyH("LEFT")
rulesFrame2.step1:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame2.step1:SetTextColor(1, 0.882, 0.596)

rulesFrame2.step1a = rulesFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2.step1a:SetPoint("TOPLEFT", rulesFrame2, 120, -130)
rulesFrame2.step1a:SetText("• Number cards (2-10) are worth their face value\n• Face cards (Jack, Queen, King) are each worth 10 points\n• Aces can be worth either 1 or 11 points")
rulesFrame2.step1a:SetJustifyH("LEFT")
rulesFrame2.step1a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame2.step1b = rulesFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2.step1b:SetPoint("TOPLEFT", rulesFrame2, 130, -223)
rulesFrame2.step1b:SetText("7        10     1/11")
rulesFrame2.step1b:SetJustifyH("LEFT")
rulesFrame2.step1b:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")

rulesFrame2.step2 = rulesFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2.step2:SetPoint("TOPLEFT", rulesFrame2, 110, -245)
rulesFrame2.step2:SetText("2. Starting the Game")
rulesFrame2.step2:SetJustifyH("LEFT")
rulesFrame2.step2:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame2.step2:SetTextColor(1, 0.882, 0.596)

rulesFrame2.step2a = rulesFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2.step2a:SetPoint("TOPLEFT", rulesFrame2, 120, -265)
rulesFrame2.step2a:SetText("• All Player's must place their bets (within the table limits) before the round\nbegins and the cards are dealt\n• Each Player will receive two cards whilst the Dealer only receives one card\n(known as the 'upcard')")
rulesFrame2.step2a:SetJustifyH("LEFT")
rulesFrame2.step2a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame2.step3 = rulesFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2.step3:SetPoint("TOPLEFT", rulesFrame2, 110, -310)
rulesFrame2.step3:SetText("3. Player's Turn")
rulesFrame2.step3:SetJustifyH("LEFT")
rulesFrame2.step3:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame2.step3:SetTextColor(1, 0.882, 0.596)

rulesFrame2.step3a = rulesFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2.step3a:SetPoint("TOPLEFT", rulesFrame2, 120, -330)
rulesFrame2.step3a:SetText("• On your turn, you must make one of the following decisions:\n\n          HIT  -  you want another card\n          STAND  -  you do not want any more cards\n          DOUBLE  -  you want to double your bet and receive one more card\n          SPLIT  -  you want to split your cards into two separate hands")
rulesFrame2.step3a:SetJustifyH("LEFT")
rulesFrame2.step3a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame2.page1 = rulesFrame2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2.page1:SetPoint("BOTTOM", rulesFrame2, 0, 57)
rulesFrame2.page1:SetText("PAGE 1")
rulesFrame2.page1:SetJustifyH("CENTER")
rulesFrame2.page1:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
rulesFrame2.page1:SetTextColor(1, 0.882, 0.596)

-- Enable click-and-drag functionality
rulesFrame2:SetMovable(true)
rulesFrame2:EnableMouse(true)
rulesFrame2:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
rulesFrame2:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

rulesFrame2:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)

-- Create a frame for the test screen
rulesFrame3 = CreateFrame("Frame", "BlackjackRules3Frame", UIParent, "BasicFrameTemplateWithInset")
rulesFrame3:SetSize(640, 475)
rulesFrame3:SetPoint("CENTER")
rulesFrame3:SetFrameStrata("HIGH")
rulesFrame3:SetFrameLevel(rulesFrame3:GetFrameLevel() + 100)
rulesFrame3:Hide()

-- Add a title to the test frame
rulesFrame3.title = rulesFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3.title:SetPoint("TOP", rulesFrame3, 0, -5)
rulesFrame3.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

rulesFrame3.background = rulesFrame3:CreateTexture(nil, "OVERLAY")
rulesFrame3.background:SetSize(1364, 682)
rulesFrame3.background:SetPoint("CENTER", rulesFrame3, 23, 2)
rulesFrame3.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Rules2.tga")
rulesFrame3.background:SetBlendMode("BLEND")
rulesFrame3.background:SetDrawLayer("ARTWORK")

rulesFrame3.returnButton = CreateFrame("Button", nil, rulesFrame3, "GameMenuButtonTemplate")
rulesFrame3.returnButton:SetPoint("TOPLEFT", rulesFrame3, 15, -35)
rulesFrame3.returnButton:SetSize(70, 25)
rulesFrame3.returnButton:SetText("Return")
rulesFrame3.returnButton:SetNormalFontObject("GameFontWhiteSmall")
rulesFrame3.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

rulesFrame3.previousPageButton = CreateFrame("Button", nil, rulesFrame3, "GameMenuButtonTemplate")
rulesFrame3.previousPageButton:SetPoint("BOTTOMLEFT", rulesFrame3, 113, 53)
rulesFrame3.previousPageButton:SetSize(110, 25)
rulesFrame3.previousPageButton:SetText("< Previous Page")
rulesFrame3.previousPageButton:SetNormalFontObject("GameFontWhiteSmall")
rulesFrame3.previousPageButton:SetHighlightFontObject("GameFontWhiteSmall")

rulesFrame3.step3b = rulesFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3.step3b:SetPoint("TOPLEFT", rulesFrame3, 120, -75)
rulesFrame3.step3b:SetText("• If the Dealer's upcard is an Ace you will be offered 'Insurance'\n\n          INSURANCE  -  you place an additional bet (half of your main bet) which\n                                  pays out at 2:1 only if the Dealer gets Blackjack\n\n          For example, you place a 200G main bet and the Dealer has an Ace.\n          You decide to place a 100G insurance bet and the Dealer gets Blackjack.\n          You lose your 200G main bet but you win 300G back from insurance,\n          allowing you to escape a Dealer Blackjack without losing anything.")
rulesFrame3.step3b:SetJustifyH("LEFT")
rulesFrame3.step3b:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame3.step4 = rulesFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3.step4:SetPoint("TOPLEFT", rulesFrame3, 110, -170)
rulesFrame3.step4:SetText("4. Dealer's Turn")
rulesFrame3.step4:SetJustifyH("LEFT")
rulesFrame3.step4:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame3.step4:SetTextColor(1, 0.882, 0.596)

rulesFrame3.step4a = rulesFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3.step4a:SetPoint("TOPLEFT", rulesFrame3, 120, -190)
rulesFrame3.step4a:SetText("• Once all Player's have finished their turn, the Dealer will begin their turn\n• The Dealer must continue to HIT until their hand totals 17 or higher")
rulesFrame3.step4a:SetJustifyH("LEFT")
rulesFrame3.step4a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame3.step5 = rulesFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3.step5:SetPoint("TOPLEFT", rulesFrame3, 110, -220)
rulesFrame3.step5:SetText("5. Blackjack")
rulesFrame3.step5:SetJustifyH("LEFT")
rulesFrame3.step5:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame3.step5:SetTextColor(1, 0.882, 0.596)

rulesFrame3.step5a = rulesFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3.step5a:SetPoint("TOPLEFT", rulesFrame3, 120, -240)
rulesFrame3.step5a:SetText("• 'Blackjack' is a special hand consisting of an Ace and any 10-point card\n• It pays out at 3:2 instead of a regular 1:1 win")
rulesFrame3.step5a:SetJustifyH("LEFT")
rulesFrame3.step5a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame3.step6 = rulesFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3.step6:SetPoint("TOPLEFT", rulesFrame3, 110, -270)
rulesFrame3.step6:SetText("6. Final Result")
rulesFrame3.step6:SetJustifyH("LEFT")
rulesFrame3.step6:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame3.step6:SetTextColor(1, 0.882, 0.596)

rulesFrame3.step6a = rulesFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3.step6a:SetPoint("TOPLEFT", rulesFrame3, 120, -290)
rulesFrame3.step6a:SetText("WIN\n          • If your hand is closer to 21 (without going over) than the Dealer\n          • If you have Blackjack and the Dealer's upcard is not an Ace or 10\n          • If the Dealer busts (goes over 21)\nPUSH\n          • If you and the Dealer have the same hand value, your bet is returned\nLOSS\n          • If your hand is lower than the Dealer (without going over 21)\n          • If you go bust (you took too many cards and went above 21)")
rulesFrame3.step6a:SetJustifyH("LEFT")
rulesFrame3.step6a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame3.page2 = rulesFrame3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3.page2:SetPoint("BOTTOM", rulesFrame3, 0, 57)
rulesFrame3.page2:SetText("PAGE 2")
rulesFrame3.page2:SetJustifyH("CENTER")
rulesFrame3.page2:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
rulesFrame3.page2:SetTextColor(1, 0.882, 0.596)

-- Enable click-and-drag functionality
rulesFrame3:SetMovable(true)
rulesFrame3:EnableMouse(true)
rulesFrame3:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
rulesFrame3:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

rulesFrame3:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)











-- Create a frame for the test screen
rulesFrameTable1 = CreateFrame("Frame", "BlackjackRules2Frame", playerFrame, "BasicFrameTemplateWithInset")
rulesFrameTable1:SetSize(640, 475)
rulesFrameTable1:SetPoint("CENTER")
rulesFrameTable1:SetFrameStrata("HIGH")
rulesFrameTable1:SetFrameLevel(rulesFrameTable1:GetFrameLevel() + 120)
rulesFrameTable1:Hide()

-- Add a title to the test frame
rulesFrameTable1.title = rulesFrameTable1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable1.title:SetPoint("TOP", rulesFrameTable1, 0, -5)
rulesFrameTable1.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

rulesFrameTable1.background = rulesFrameTable1:CreateTexture(nil, "OVERLAY")
rulesFrameTable1.background:SetSize(1364, 682)
rulesFrameTable1.background:SetPoint("CENTER", rulesFrameTable1, 23, 2)
rulesFrameTable1.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Rules.tga")
rulesFrameTable1.background:SetBlendMode("BLEND")
rulesFrameTable1.background:SetDrawLayer("ARTWORK")

rulesFrameTable1.nextPageButton = CreateFrame("Button", nil, rulesFrameTable1, "GameMenuButtonTemplate")
rulesFrameTable1.nextPageButton:SetPoint("BOTTOMRIGHT", rulesFrameTable1, -113, 53)
rulesFrameTable1.nextPageButton:SetSize(110, 25)
rulesFrameTable1.nextPageButton:SetText("Next Page >")
rulesFrameTable1.nextPageButton:SetNormalFontObject("GameFontWhiteSmall")
rulesFrameTable1.nextPageButton:SetHighlightFontObject("GameFontWhiteSmall")

rulesFrameTable1.step1 = rulesFrameTable1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable1.step1:SetPoint("TOPLEFT", rulesFrameTable1, 110, -110)
rulesFrameTable1.step1:SetText("1. Card Values")
rulesFrameTable1.step1:SetJustifyH("LEFT")
rulesFrameTable1.step1:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrameTable1.step1:SetTextColor(1, 0.882, 0.596)

rulesFrameTable1.step1a = rulesFrameTable1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable1.step1a:SetPoint("TOPLEFT", rulesFrameTable1, 120, -130)
rulesFrameTable1.step1a:SetText("• Number cards (2-10) are worth their face value\n• Face cards (Jack, Queen, King) are each worth 10 points\n• Aces can be worth either 1 or 11 points")
rulesFrameTable1.step1a:SetJustifyH("LEFT")
rulesFrameTable1.step1a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrameTable1.step1b = rulesFrameTable1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable1.step1b:SetPoint("TOPLEFT", rulesFrameTable1, 130, -223)
rulesFrameTable1.step1b:SetText("7        10     1/11")
rulesFrameTable1.step1b:SetJustifyH("LEFT")
rulesFrameTable1.step1b:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")

rulesFrameTable1.step2 = rulesFrameTable1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable1.step2:SetPoint("TOPLEFT", rulesFrameTable1, 110, -245)
rulesFrameTable1.step2:SetText("2. Starting the Game")
rulesFrameTable1.step2:SetJustifyH("LEFT")
rulesFrameTable1.step2:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrameTable1.step2:SetTextColor(1, 0.882, 0.596)

rulesFrameTable1.step2a = rulesFrameTable1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable1.step2a:SetPoint("TOPLEFT", rulesFrameTable1, 120, -265)
rulesFrameTable1.step2a:SetText("• All Player's must place their bets (within the table limits) before the round\nbegins and the cards are dealt\n• Each Player will receive two cards whilst the Dealer only receives one card\n(known as the 'upcard')")
rulesFrameTable1.step2a:SetJustifyH("LEFT")
rulesFrameTable1.step2a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrameTable1.step3 = rulesFrameTable1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable1.step3:SetPoint("TOPLEFT", rulesFrameTable1, 110, -310)
rulesFrameTable1.step3:SetText("3. Player's Turn")
rulesFrameTable1.step3:SetJustifyH("LEFT")
rulesFrameTable1.step3:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrameTable1.step3:SetTextColor(1, 0.882, 0.596)

rulesFrameTable1.step3a = rulesFrameTable1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable1.step3a:SetPoint("TOPLEFT", rulesFrameTable1, 120, -330)
rulesFrameTable1.step3a:SetText("• On your turn, you must make one of the following decisions:\n\n          HIT  -  you want another card\n          STAND  -  you do not want any more cards\n          DOUBLE  -  you want to double your bet and receive one more card\n          SPLIT  -  you want to split your cards into two separate hands")
rulesFrameTable1.step3a:SetJustifyH("LEFT")
rulesFrameTable1.step3a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrameTable1.page1 = rulesFrameTable1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable1.page1:SetPoint("BOTTOM", rulesFrameTable1, 0, 57)
rulesFrameTable1.page1:SetText("PAGE 1")
rulesFrameTable1.page1:SetJustifyH("CENTER")
rulesFrameTable1.page1:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
rulesFrameTable1.page1:SetTextColor(1, 0.882, 0.596)

-- Create a frame for the test screen
rulesFrameTable2 = CreateFrame("Frame", "BlackjackRules3Frame", playerFrame, "BasicFrameTemplateWithInset")
rulesFrameTable2:SetSize(640, 475)
rulesFrameTable2:SetPoint("CENTER")
rulesFrameTable2:SetFrameStrata("HIGH")
rulesFrameTable2:SetFrameLevel(rulesFrameTable2:GetFrameLevel() + 120)
rulesFrameTable2:Hide()

-- Add a title to the test frame
rulesFrameTable2.title = rulesFrameTable2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable2.title:SetPoint("TOP", rulesFrameTable2, 0, -5)
rulesFrameTable2.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

rulesFrameTable2.background = rulesFrameTable2:CreateTexture(nil, "OVERLAY")
rulesFrameTable2.background:SetSize(1364, 682)
rulesFrameTable2.background:SetPoint("CENTER", rulesFrameTable2, 23, 2)
rulesFrameTable2.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Rules2.tga")
rulesFrameTable2.background:SetBlendMode("BLEND")
rulesFrameTable2.background:SetDrawLayer("ARTWORK")

rulesFrameTable2.previousPageButton = CreateFrame("Button", nil, rulesFrameTable2, "GameMenuButtonTemplate")
rulesFrameTable2.previousPageButton:SetPoint("BOTTOMLEFT", rulesFrameTable2, 113, 53)
rulesFrameTable2.previousPageButton:SetSize(110, 25)
rulesFrameTable2.previousPageButton:SetText("< Previous Page")
rulesFrameTable2.previousPageButton:SetNormalFontObject("GameFontWhiteSmall")
rulesFrameTable2.previousPageButton:SetHighlightFontObject("GameFontWhiteSmall")

rulesFrameTable2.step3b = rulesFrameTable2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable2.step3b:SetPoint("TOPLEFT", rulesFrameTable2, 120, -75)
rulesFrameTable2.step3b:SetText("• If the Dealer's upcard is an Ace you will be offered 'Insurance'\n\n          INSURANCE  -  you place an additional bet (half of your main bet) which\n                                  pays out at 2:1 only if the Dealer gets Blackjack\n\n          For example, you place a 200G main bet and the Dealer has an Ace.\n          You decide to place a 100G insurance bet and the Dealer gets Blackjack.\n          You lose your 200G main bet but you win 300G back from insurance,\n          allowing you to escape a Dealer Blackjack without losing anything.")
rulesFrameTable2.step3b:SetJustifyH("LEFT")
rulesFrameTable2.step3b:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrameTable2.step4 = rulesFrameTable2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable2.step4:SetPoint("TOPLEFT", rulesFrameTable2, 110, -170)
rulesFrameTable2.step4:SetText("4. Dealer's Turn")
rulesFrameTable2.step4:SetJustifyH("LEFT")
rulesFrameTable2.step4:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrameTable2.step4:SetTextColor(1, 0.882, 0.596)

rulesFrameTable2.step4a = rulesFrameTable2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable2.step4a:SetPoint("TOPLEFT", rulesFrameTable2, 120, -190)
rulesFrameTable2.step4a:SetText("• Once all Player's have finished their turn, the Dealer will begin their turn\n• The Dealer must continue to HIT until their hand totals 17 or higher")
rulesFrameTable2.step4a:SetJustifyH("LEFT")
rulesFrameTable2.step4a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrameTable2.step5 = rulesFrameTable2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable2.step5:SetPoint("TOPLEFT", rulesFrameTable2, 110, -220)
rulesFrameTable2.step5:SetText("5. Blackjack")
rulesFrameTable2.step5:SetJustifyH("LEFT")
rulesFrameTable2.step5:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrameTable2.step5:SetTextColor(1, 0.882, 0.596)

rulesFrameTable2.step5a = rulesFrameTable2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable2.step5a:SetPoint("TOPLEFT", rulesFrameTable2, 120, -240)
rulesFrameTable2.step5a:SetText("• 'Blackjack' is a special hand consisting of an Ace and any 10-point card\n• It pays out at 3:2 instead of a regular 1:1 win")
rulesFrameTable2.step5a:SetJustifyH("LEFT")
rulesFrameTable2.step5a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrameTable2.step6 = rulesFrameTable2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable2.step6:SetPoint("TOPLEFT", rulesFrameTable2, 110, -270)
rulesFrameTable2.step6:SetText("6. Final Result")
rulesFrameTable2.step6:SetJustifyH("LEFT")
rulesFrameTable2.step6:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrameTable2.step6:SetTextColor(1, 0.882, 0.596)

rulesFrameTable2.step6a = rulesFrameTable2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable2.step6a:SetPoint("TOPLEFT", rulesFrameTable2, 120, -290)
rulesFrameTable2.step6a:SetText("WIN\n          • If your hand is closer to 21 (without going over) than the Dealer\n          • If you have Blackjack and the Dealer's upcard is not an Ace or 10\n          • If the Dealer busts (goes over 21)\nPUSH\n          • If you and the Dealer have the same hand value, your bet is returned\nLOSS\n          • If your hand is lower than the Dealer (without going over 21)\n          • If you go bust (you took too many cards and went above 21)")
rulesFrameTable2.step6a:SetJustifyH("LEFT")
rulesFrameTable2.step6a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrameTable2.page2 = rulesFrameTable2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrameTable2.page2:SetPoint("BOTTOM", rulesFrameTable2, 0, 57)
rulesFrameTable2.page2:SetText("PAGE 2")
rulesFrameTable2.page2:SetJustifyH("CENTER")
rulesFrameTable2.page2:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
rulesFrameTable2.page2:SetTextColor(1, 0.882, 0.596)

























-- Create a frame for the test screen
tutorialFrameDealer = CreateFrame("Frame", "BlackjacktutorialFrameDealer", UIParent, "BasicFrameTemplateWithInset")
tutorialFrameDealer:SetSize(640, 475)
tutorialFrameDealer:SetPoint("CENTER")
tutorialFrameDealer:SetFrameStrata("HIGH")
tutorialFrameDealer:SetFrameLevel(tutorialFrameDealer:GetFrameLevel() + 100)
tutorialFrameDealer:Hide()

-- Add a title to the test frame
tutorialFrameDealer.title = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.title:SetPoint("TOP", tutorialFrameDealer, 0, -5)
tutorialFrameDealer.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

tutorialFrameDealer.background = tutorialFrameDealer:CreateTexture(nil, "OVERLAY")
tutorialFrameDealer.background:SetSize(1364, 682)
tutorialFrameDealer.background:SetPoint("CENTER", tutorialFrameDealer, 23, 2)
tutorialFrameDealer.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Tutorial.tga")
tutorialFrameDealer.background:SetBlendMode("BLEND")
tutorialFrameDealer.background:SetDrawLayer("ARTWORK")

tutorialFrameDealer.returnButton = CreateFrame("Button", nil, tutorialFrameDealer, "GameMenuButtonTemplate")
tutorialFrameDealer.returnButton:SetPoint("TOPLEFT", tutorialFrameDealer, 15, -35)
tutorialFrameDealer.returnButton:SetSize(70, 25)
tutorialFrameDealer.returnButton:SetText("Return")
tutorialFrameDealer.returnButton:SetNormalFontObject("GameFontWhiteSmall")
tutorialFrameDealer.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

tutorialFrameDealer.playerButton = CreateFrame("Button", nil, tutorialFrameDealer, "GameMenuButtonTemplate")
tutorialFrameDealer.playerButton:SetPoint("TOP", tutorialFrameDealer, -50, -110)
tutorialFrameDealer.playerButton:SetSize(90, 30)
tutorialFrameDealer.playerButton:SetText("Player")
tutorialFrameDealer.playerButton:Disable()

tutorialFrameDealer.dealerButton = CreateFrame("Button", nil, tutorialFrameDealer, "GameMenuButtonTemplate")
tutorialFrameDealer.dealerButton:SetPoint("TOP", tutorialFrameDealer, 50, -110)
tutorialFrameDealer.dealerButton:SetSize(90, 30)
tutorialFrameDealer.dealerButton:SetText("Dealer")

tutorialFrameDealer.step1 = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step1:SetPoint("TOPLEFT", tutorialFrameDealer, 110, -155)
tutorialFrameDealer.step1:SetText("1. Join a raid group with the host (Dealer)")
tutorialFrameDealer.step1:SetJustifyH("LEFT")
tutorialFrameDealer.step1:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer.step1:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer.step1a = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step1a:SetPoint("TOPLEFT", tutorialFrameDealer, 120, -175)
tutorialFrameDealer.step1a:SetText("• Ensure you are NOT the raid leader if you plan on joining as a Player")
tutorialFrameDealer.step1a:SetJustifyH("LEFT")
tutorialFrameDealer.step1a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrameDealer.step2 = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step2:SetPoint("TOPLEFT", tutorialFrameDealer, 110, -195)
tutorialFrameDealer.step2:SetText("2. Politely ask the Dealer to open up the table for you")
tutorialFrameDealer.step2:SetJustifyH("LEFT")
tutorialFrameDealer.step2:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer.step2:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer.step2a = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step2a:SetPoint("TOPLEFT", tutorialFrameDealer, 120, -215)
tutorialFrameDealer.step2a:SetText("• The table will need to be opened even if there is already an active table")
tutorialFrameDealer.step2a:SetJustifyH("LEFT")
tutorialFrameDealer.step2a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrameDealer.step3 = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step3:SetPoint("TOPLEFT", tutorialFrameDealer, 110, -235)
tutorialFrameDealer.step3:SetText("3. Click the 'Join Table' button and choose an available seat")
tutorialFrameDealer.step3:SetJustifyH("LEFT")
tutorialFrameDealer.step3:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer.step3:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer.step3a = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step3a:SetPoint("TOPLEFT", tutorialFrameDealer, 120, -255)
tutorialFrameDealer.step3a:SetText("• If the table is full you can still observe as a spectator until one becomes free")
tutorialFrameDealer.step3a:SetJustifyH("LEFT")
tutorialFrameDealer.step3a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrameDealer.step4 = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step4:SetPoint("TOPLEFT", tutorialFrameDealer, 110, -275)
tutorialFrameDealer.step4:SetText("4. Click the 'Cash Desk' button in the bottom-left corner")
tutorialFrameDealer.step4:SetJustifyH("LEFT")
tutorialFrameDealer.step4:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer.step4:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer.step4a = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step4a:SetPoint("TOPLEFT", tutorialFrameDealer, 120, -295)
tutorialFrameDealer.step4a:SetText("• This is where you will complete any deposit/withdrawal of funds to play with\n• Deposits and withdrawals should only take place between rounds")
tutorialFrameDealer.step4a:SetJustifyH("LEFT")
tutorialFrameDealer.step4a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrameDealer.step5 = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step5:SetPoint("TOPLEFT", tutorialFrameDealer, 110, -325)
tutorialFrameDealer.step5:SetText("5. Return to the table and place a bet using the 'Bet' buttons")
tutorialFrameDealer.step5:SetJustifyH("LEFT")
tutorialFrameDealer.step5:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer.step5:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer.step5a = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step5a:SetPoint("TOPLEFT", tutorialFrameDealer, 120, -345)
tutorialFrameDealer.step5a:SetText("• Placing a 'Main Bet' is mandatory but side bets are entirely optional\n• Ensure your bets are within the defined table limits set by the Dealer")
tutorialFrameDealer.step5a:SetJustifyH("LEFT")
tutorialFrameDealer.step5a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrameDealer.step6 = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step6:SetPoint("TOPLEFT", tutorialFrameDealer, 110, -375)
tutorialFrameDealer.step6:SetText("6. Play the game!")
tutorialFrameDealer.step6:SetJustifyH("LEFT")
tutorialFrameDealer.step6:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer.step6:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer.step6a = tutorialFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer.step6a:SetPoint("TOPLEFT", tutorialFrameDealer, 120, -395)
tutorialFrameDealer.step6a:SetText("• Once the round has started, you will be asked to make decisions on your turn\n• Refer to the 'Rules' page on the previous screen to learn how to play")
tutorialFrameDealer.step6a:SetJustifyH("LEFT")
tutorialFrameDealer.step6a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Enable click-and-drag functionality
tutorialFrameDealer:SetMovable(true)
tutorialFrameDealer:EnableMouse(true)
tutorialFrameDealer:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
tutorialFrameDealer:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

tutorialFrameDealer:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)


-- Create a frame for the test screen
tutorialFrameDealer2 = CreateFrame("Frame", "BlackjacktutorialFrameDealer2", UIParent, "BasicFrameTemplateWithInset")
tutorialFrameDealer2:SetSize(640, 475)
tutorialFrameDealer2:SetPoint("CENTER")
tutorialFrameDealer2:SetFrameStrata("HIGH")
tutorialFrameDealer2:SetFrameLevel(tutorialFrameDealer2:GetFrameLevel() + 100)
tutorialFrameDealer2:Hide()

-- Add a title to the test frame
tutorialFrameDealer2.title = tutorialFrameDealer2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer2.title:SetPoint("TOP", tutorialFrameDealer2, 0, -5)
tutorialFrameDealer2.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

tutorialFrameDealer2.background = tutorialFrameDealer2:CreateTexture(nil, "OVERLAY")
tutorialFrameDealer2.background:SetSize(1364, 682)
tutorialFrameDealer2.background:SetPoint("CENTER", tutorialFrameDealer2, 23, 2)
tutorialFrameDealer2.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Tutorial2.tga")
tutorialFrameDealer2.background:SetBlendMode("BLEND")
tutorialFrameDealer2.background:SetDrawLayer("ARTWORK")

tutorialFrameDealer2.returnButton = CreateFrame("Button", nil, tutorialFrameDealer2, "GameMenuButtonTemplate")
tutorialFrameDealer2.returnButton:SetPoint("TOPLEFT", tutorialFrameDealer2, 15, -35)
tutorialFrameDealer2.returnButton:SetSize(70, 25)
tutorialFrameDealer2.returnButton:SetText("Return")
tutorialFrameDealer2.returnButton:SetNormalFontObject("GameFontWhiteSmall")
tutorialFrameDealer2.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

tutorialFrameDealer2.playerButton = CreateFrame("Button", nil, tutorialFrameDealer2, "GameMenuButtonTemplate")
tutorialFrameDealer2.playerButton:SetPoint("TOP", tutorialFrameDealer2, -50, -110)
tutorialFrameDealer2.playerButton:SetSize(90, 30)
tutorialFrameDealer2.playerButton:SetText("Player")

tutorialFrameDealer2.dealerButton = CreateFrame("Button", nil, tutorialFrameDealer2, "GameMenuButtonTemplate")
tutorialFrameDealer2.dealerButton:SetPoint("TOP", tutorialFrameDealer2, 50, -110)
tutorialFrameDealer2.dealerButton:SetSize(90, 30)
tutorialFrameDealer2.dealerButton:SetText("Dealer")
tutorialFrameDealer2.dealerButton:Disable()

tutorialFrameDealer2.step1 = tutorialFrameDealer2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer2.step1:SetPoint("TOPLEFT", tutorialFrameDealer2, 110, -155)
tutorialFrameDealer2.step1:SetText("1. Invite a Player (or Player's) to a raid group")
tutorialFrameDealer2.step1:SetJustifyH("LEFT")
tutorialFrameDealer2.step1:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer2.step1:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer2.step1a = tutorialFrameDealer2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer2.step1a:SetPoint("TOPLEFT", tutorialFrameDealer2, 120, -175)
tutorialFrameDealer2.step1a:SetText("• Ensure you ARE the raid leader before selecting the 'DEALER' option")
tutorialFrameDealer2.step1a:SetJustifyH("LEFT")
tutorialFrameDealer2.step1a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrameDealer2.step2 = tutorialFrameDealer2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer2.step2:SetPoint("TOPLEFT", tutorialFrameDealer2, 110, -195)
tutorialFrameDealer2.step2:SetText("2. Click the 'Open Table' button on the Dealer UI")
tutorialFrameDealer2.step2:SetJustifyH("LEFT")
tutorialFrameDealer2.step2:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer2.step2:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer2.step2a = tutorialFrameDealer2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer2.step2a:SetPoint("TOPLEFT", tutorialFrameDealer2, 120, -215)
tutorialFrameDealer2.step2a:SetText("• This will enable the 'Join Table' button for Player's\n\n• IMPORTANT  -  If you have an active table and want to invite a new Player,\n                            make sure that the table is clear and nobody places a bet\n                            before they have joined the raid group. This has been known\n                            to cause issues and crash the AddOn")
tutorialFrameDealer2.step2a:SetJustifyH("LEFT")
tutorialFrameDealer2.step2a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrameDealer2.step3 = tutorialFrameDealer2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer2.step3:SetPoint("TOPLEFT", tutorialFrameDealer2, 110, -285)
tutorialFrameDealer2.step3:SetText("3. Update Player bankrolls using the '+' and '-' buttons")
tutorialFrameDealer2.step3:SetJustifyH("LEFT")
tutorialFrameDealer2.step3:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer2.step3:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer2.step3a = tutorialFrameDealer2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer2.step3a:SetPoint("TOPLEFT", tutorialFrameDealer2, 120, -305)
tutorialFrameDealer2.step3a:SetText("• Whenever a Player visits the Cash Desk and wants to make a deposit or\nwithdrawal, remember to update the values accordingly on your banking tab")
tutorialFrameDealer2.step3a:SetJustifyH("LEFT")
tutorialFrameDealer2.step3a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrameDealer2.step4 = tutorialFrameDealer2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer2.step4:SetPoint("TOPLEFT", tutorialFrameDealer2, 110, -335)
tutorialFrameDealer2.step4:SetText("4. Encourage Player's to place their bets in a timely manner")
tutorialFrameDealer2.step4:SetJustifyH("LEFT")
tutorialFrameDealer2.step4:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer2.step4:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer2.step4a = tutorialFrameDealer2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer2.step4a:SetPoint("TOPLEFT", tutorialFrameDealer2, 120, -355)
tutorialFrameDealer2.step4a:SetText("• Once all bets have been placed you can start dealing the cards using the\n'Deal Cards' button at the bottom\n• Keep clicking 'Deal Cards' until every Player has two cards and you have one")
tutorialFrameDealer2.step4a:SetJustifyH("LEFT")
tutorialFrameDealer2.step4a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrameDealer2.page1 = tutorialFrameDealer2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer2.page1:SetPoint("BOTTOM", tutorialFrameDealer2, 0, 57)
tutorialFrameDealer2.page1:SetText("PAGE 1")
tutorialFrameDealer2.page1:SetJustifyH("CENTER")
tutorialFrameDealer2.page1:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
tutorialFrameDealer2.page1:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer2.nextPageButton = CreateFrame("Button", nil, tutorialFrameDealer2, "GameMenuButtonTemplate")
tutorialFrameDealer2.nextPageButton:SetPoint("BOTTOMRIGHT", tutorialFrameDealer2, -113, 53)
tutorialFrameDealer2.nextPageButton:SetSize(110, 25)
tutorialFrameDealer2.nextPageButton:SetText("Next Page >")
tutorialFrameDealer2.nextPageButton:SetNormalFontObject("GameFontWhiteSmall")
tutorialFrameDealer2.nextPageButton:SetHighlightFontObject("GameFontWhiteSmall")

-- Enable click-and-drag functionality
tutorialFrameDealer2:SetMovable(true)
tutorialFrameDealer2:EnableMouse(true)
tutorialFrameDealer2:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
tutorialFrameDealer2:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

tutorialFrameDealer2:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)

-- Create a frame for the test screen
tutorialFrameDealer3 = CreateFrame("Frame", "BlackjacktutorialFrameDealer3", UIParent, "BasicFrameTemplateWithInset")
tutorialFrameDealer3:SetSize(640, 475)
tutorialFrameDealer3:SetPoint("CENTER")
tutorialFrameDealer3:SetFrameStrata("HIGH")
tutorialFrameDealer3:SetFrameLevel(tutorialFrameDealer3:GetFrameLevel() + 100)
tutorialFrameDealer3:Hide()

-- Add a title to the test frame
tutorialFrameDealer3.title = tutorialFrameDealer3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer3.title:SetPoint("TOP", tutorialFrameDealer3, 0, -5)
tutorialFrameDealer3.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

tutorialFrameDealer3.background = tutorialFrameDealer3:CreateTexture(nil, "OVERLAY")
tutorialFrameDealer3.background:SetSize(1364, 682)
tutorialFrameDealer3.background:SetPoint("CENTER", tutorialFrameDealer3, 23, 2)
tutorialFrameDealer3.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Tutorial2.tga")
tutorialFrameDealer3.background:SetBlendMode("BLEND")
tutorialFrameDealer3.background:SetDrawLayer("ARTWORK")

tutorialFrameDealer3.returnButton = CreateFrame("Button", nil, tutorialFrameDealer3, "GameMenuButtonTemplate")
tutorialFrameDealer3.returnButton:SetPoint("TOPLEFT", tutorialFrameDealer3, 15, -35)
tutorialFrameDealer3.returnButton:SetSize(70, 25)
tutorialFrameDealer3.returnButton:SetText("Return")
tutorialFrameDealer3.returnButton:SetNormalFontObject("GameFontWhiteSmall")
tutorialFrameDealer3.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

tutorialFrameDealer3.playerButton = CreateFrame("Button", nil, tutorialFrameDealer3, "GameMenuButtonTemplate")
tutorialFrameDealer3.playerButton:SetPoint("TOP", tutorialFrameDealer3, -50, -110)
tutorialFrameDealer3.playerButton:SetSize(90, 30)
tutorialFrameDealer3.playerButton:SetText("Player")

tutorialFrameDealer3.dealerButton = CreateFrame("Button", nil, tutorialFrameDealer3, "GameMenuButtonTemplate")
tutorialFrameDealer3.dealerButton:SetPoint("TOP", tutorialFrameDealer3, 50, -110)
tutorialFrameDealer3.dealerButton:SetSize(90, 30)
tutorialFrameDealer3.dealerButton:SetText("Dealer")
tutorialFrameDealer3.dealerButton:Disable()

tutorialFrameDealer3.previousPageButton = CreateFrame("Button", nil, tutorialFrameDealer3, "GameMenuButtonTemplate")
tutorialFrameDealer3.previousPageButton:SetPoint("BOTTOMLEFT", tutorialFrameDealer3, 113, 53)
tutorialFrameDealer3.previousPageButton:SetSize(110, 25)
tutorialFrameDealer3.previousPageButton:SetText("< Previous Page")
tutorialFrameDealer3.previousPageButton:SetNormalFontObject("GameFontWhiteSmall")
tutorialFrameDealer3.previousPageButton:SetHighlightFontObject("GameFontWhiteSmall")

tutorialFrameDealer3.page1 = tutorialFrameDealer3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer3.page1:SetPoint("BOTTOM", tutorialFrameDealer3, 0, 57)
tutorialFrameDealer3.page1:SetText("PAGE 2")
tutorialFrameDealer3.page1:SetJustifyH("CENTER")
tutorialFrameDealer3.page1:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
tutorialFrameDealer3.page1:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer3.step5 = tutorialFrameDealer3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer3.step5:SetPoint("TOPLEFT", tutorialFrameDealer3, 110, -155)
tutorialFrameDealer3.step5:SetText("5. Observe the Player's decisions and react accordingly")
tutorialFrameDealer3.step5:SetJustifyH("LEFT")
tutorialFrameDealer3.step5:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer3.step5:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer3.step5a = tutorialFrameDealer3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer3.step5a:SetPoint("TOPLEFT", tutorialFrameDealer3, 120, -175)
tutorialFrameDealer3.step5a:SetText("• Keep an eye on the chatbox to see what the Player's choose to do:\n\n          HIT  -  click the 'Deal Cards' button once\n          STAND  -  wait for the next Player's decision\n          DOUBLE  -  click the 'Deal Cards' button once\n          SPLIT  -  click the 'Deal Cards' button twice\n\n• Whenever its your turn (e.g. the last player has chosen STAND or DOUBLE) you\nmust keep hitting the 'Deal Cards' button until you have a total of at least 17")
tutorialFrameDealer3.step5a:SetJustifyH("LEFT")
tutorialFrameDealer3.step5a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrameDealer3.step6 = tutorialFrameDealer3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer3.step6:SetPoint("TOPLEFT", tutorialFrameDealer3, 110, -265)
tutorialFrameDealer3.step6:SetText("6. Wait for the final result and then reset the table")
tutorialFrameDealer3.step6:SetJustifyH("LEFT")
tutorialFrameDealer3.step6:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer3.step6:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer3.step6a = tutorialFrameDealer3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer3.step6a:SetPoint("TOPLEFT", tutorialFrameDealer3, 120, -285)
tutorialFrameDealer3.step6a:SetText("• Once you have a hand total of 17 or more, the results for each player will be\nannounced automatically over a period of 2-10 seconds\n• Bankroll totals will update for both the Dealer and Player's in real-time\n• Wait until this announcement has finished before starting a new round\n• Hit the 'New Game' button to reset and wipe the table clean")
tutorialFrameDealer3.step6a:SetJustifyH("LEFT")
tutorialFrameDealer3.step6a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

tutorialFrameDealer3.step7 = tutorialFrameDealer3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer3.step7:SetPoint("TOPLEFT", tutorialFrameDealer3, 110, -340)
tutorialFrameDealer3.step7:SetText("7. Don't forget to shuffle!")
tutorialFrameDealer3.step7:SetJustifyH("LEFT")
tutorialFrameDealer3.step7:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
tutorialFrameDealer3.step7:SetTextColor(1, 0.882, 0.596)

tutorialFrameDealer3.step7a = tutorialFrameDealer3:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
tutorialFrameDealer3.step7a:SetPoint("TOPLEFT", tutorialFrameDealer3, 120, -360)
tutorialFrameDealer3.step7a:SetText("• Keep an eye on the '/roll' number in chat - this lowers as the game goes on\n• Hit the 'Shuffle Deck' button at the END of a round when the number gets\nlow - if you forget and it hits 1 then no more cards will be generated")
tutorialFrameDealer3.step7a:SetJustifyH("LEFT")
tutorialFrameDealer3.step7a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Enable click-and-drag functionality
tutorialFrameDealer3:SetMovable(true)
tutorialFrameDealer3:EnableMouse(true)
tutorialFrameDealer3:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
tutorialFrameDealer3:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

tutorialFrameDealer3:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)





-- Create a frame for the test screen
faqsFrameDealer = CreateFrame("Frame", "BlackjackfaqsFrameDealer", UIParent, "BasicFrameTemplateWithInset")
faqsFrameDealer:SetSize(640, 475)
faqsFrameDealer:SetPoint("CENTER")
faqsFrameDealer:SetFrameStrata("HIGH")
faqsFrameDealer:SetFrameLevel(faqsFrameDealer:GetFrameLevel() + 100)
faqsFrameDealer:Hide()

-- Add a title to the test frame
faqsFrameDealer.title = faqsFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrameDealer.title:SetPoint("TOP", faqsFrameDealer, 0, -5)
faqsFrameDealer.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

faqsFrameDealer.background = faqsFrameDealer:CreateTexture(nil, "OVERLAY")
faqsFrameDealer.background:SetSize(1364, 682)
faqsFrameDealer.background:SetPoint("CENTER", faqsFrameDealer, 23, 2)
faqsFrameDealer.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\FAQs.tga")
faqsFrameDealer.background:SetBlendMode("BLEND")
faqsFrameDealer.background:SetDrawLayer("ARTWORK")

faqsFrameDealer.returnButton = CreateFrame("Button", nil, faqsFrameDealer, "GameMenuButtonTemplate")
faqsFrameDealer.returnButton:SetPoint("TOPLEFT", faqsFrameDealer, 15, -35)
faqsFrameDealer.returnButton:SetSize(70, 25)
faqsFrameDealer.returnButton:SetText("Return")
faqsFrameDealer.returnButton:SetNormalFontObject("GameFontWhiteSmall")
faqsFrameDealer.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

faqsFrameDealer.faq1 = faqsFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrameDealer.faq1:SetPoint("TOPLEFT", faqsFrameDealer, 110, -110)
faqsFrameDealer.faq1:SetText("1. Why was the Blackjack AddOn created in the first place?")
faqsFrameDealer.faq1:SetJustifyH("LEFT")
faqsFrameDealer.faq1:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
faqsFrameDealer.faq1:SetTextColor(1, 0.882, 0.596)

faqsFrameDealer.faq1a = faqsFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrameDealer.faq1a:SetPoint("TOPLEFT", faqsFrameDealer, 120, -130)
faqsFrameDealer.faq1a:SetText("It was developed to replace 'death-rolling' between friends, guild-mates or\nraid-party members, as a more fun (and immersive) alternative")
faqsFrameDealer.faq1a:SetJustifyH("LEFT")
faqsFrameDealer.faq1a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

faqsFrameDealer.faq2 = faqsFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrameDealer.faq2:SetPoint("TOPLEFT", faqsFrameDealer, 110, -160)
faqsFrameDealer.faq2:SetText("2. How can I be sure the cards are generated (dealt on the table)\n    fairly and with 100% randomisation?")
faqsFrameDealer.faq2:SetJustifyH("LEFT")
faqsFrameDealer.faq2:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
faqsFrameDealer.faq2:SetTextColor(1, 0.882, 0.596)

faqsFrameDealer.faq2a = faqsFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrameDealer.faq2a:SetPoint("TOPLEFT", faqsFrameDealer, 120, -190)
faqsFrameDealer.faq2a:SetText("All cards are generated using the in-game WoW command '/roll' meaning that\nall Player's (and the Dealer) witness the result at the same time. For a more\ndetailed, technical explanation, please read the FAQs section on CurseForge")
faqsFrameDealer.faq2a:SetJustifyH("LEFT")
faqsFrameDealer.faq2a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

faqsFrameDealer.faq3 = faqsFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrameDealer.faq3:SetPoint("TOPLEFT", faqsFrameDealer, 110, -230)
faqsFrameDealer.faq3:SetText("3. What is the likelihood that I win whilst playing with this\n    AddOn, and how do I know it's not totally rigged?")
faqsFrameDealer.faq3:SetJustifyH("LEFT")
faqsFrameDealer.faq3:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
faqsFrameDealer.faq3:SetTextColor(1, 0.882, 0.596)

faqsFrameDealer.faq3a = faqsFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrameDealer.faq3a:SetPoint("TOPLEFT", faqsFrameDealer, 120, -260)
faqsFrameDealer.faq3a:SetText("It's important to note that blackjack, like any casino game, comes with an\ninherent house edge (advantage). In blackjack, this house edge depends upon a\nnumber of factors, including but not limited to, the Player's ability to double\nsplit, and surrender; the Dealer standing on soft-17 (Ace + 6); the number of\ndecks used in the shoe; how often the deck is shuffled; and whether the player\nis following perfect 'Blackjack Strategy' - the chart for this can be found below")
faqsFrameDealer.faq3a:SetJustifyH("LEFT")
faqsFrameDealer.faq3a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

faqsFrameDealer.chartButton = CreateFrame("Button", nil, faqsFrameDealer, "GameMenuButtonTemplate")
faqsFrameDealer.chartButton:SetPoint("TOPLEFT", faqsFrameDealer, 119, -322)
faqsFrameDealer.chartButton:SetSize(150, 25)
faqsFrameDealer.chartButton:SetText("Blackjack Strategy Chart")
faqsFrameDealer.chartButton:SetNormalFontObject("GameFontWhiteSmall")
faqsFrameDealer.chartButton:SetHighlightFontObject("GameFontWhiteSmall")

faqsFrameDealer.chartButton:SetScript("OnClick", function()
    StaticPopupDialogs["WEBSITE_LINK"] = {
        text = "Copy the link below into a web browser:",
        button1 = "Close",
        hasEditBox = true,
        hasWideEditBox = true,
        editBoxWidth = 260,
        timeout = 0,
        whileDead = true,
        hideOnEscape = true,
        preferredIndex = STATICPOPUP_NUMDIALOGS,
    }

    dialog = StaticPopup_Show("WEBSITE_LINK")
    dialog.editBox:SetText("https://www.blackjackapprenticeship.com/wp-content/uploads/2018/10/mini-blackjack-strategy-chart.png")
    dialog.editBox:SetFocus()
    dialog.editBox:HighlightText()
end)

faqsFrameDealer.faq4 = faqsFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrameDealer.faq4:SetPoint("TOPLEFT", faqsFrameDealer, 110, -355)
faqsFrameDealer.faq4:SetText("4. How do I increase the table limits, or change the number of\n     decks in the shoe, if I'm hosting a table as the Dealer?")
faqsFrameDealer.faq4:SetJustifyH("LEFT")
faqsFrameDealer.faq4:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
faqsFrameDealer.faq4:SetTextColor(1, 0.882, 0.596)

faqsFrameDealer.faq4a = faqsFrameDealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
faqsFrameDealer.faq4a:SetPoint("TOPLEFT", faqsFrameDealer, 120, -385)
faqsFrameDealer.faq4a:SetText("To be able to fully customise your table experience you must become a\n'Licensed Dealer' - this will grant you access to additional features and your\ncharacter will be displayed on the AddOn UI. Visit www.wowblackjack.com")
faqsFrameDealer.faq4a:SetJustifyH("LEFT")
faqsFrameDealer.faq4a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Enable click-and-drag functionality
faqsFrameDealer:SetMovable(true)
faqsFrameDealer:EnableMouse(true)
faqsFrameDealer:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
faqsFrameDealer:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

faqsFrameDealer:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)






-- Create a frame for the test screen
rulesFrame2Dealer = CreateFrame("Frame", "BlackjackRules2Frame", UIParent, "BasicFrameTemplateWithInset")
rulesFrame2Dealer:SetSize(640, 475)
rulesFrame2Dealer:SetPoint("CENTER")
rulesFrame2Dealer:SetFrameStrata("HIGH")
rulesFrame2Dealer:SetFrameLevel(rulesFrame2Dealer:GetFrameLevel() + 100)
rulesFrame2Dealer:Hide()

-- Add a title to the test frame
rulesFrame2Dealer.title = rulesFrame2Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2Dealer.title:SetPoint("TOP", rulesFrame2Dealer, 0, -5)
rulesFrame2Dealer.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

rulesFrame2Dealer.background = rulesFrame2Dealer:CreateTexture(nil, "OVERLAY")
rulesFrame2Dealer.background:SetSize(1364, 682)
rulesFrame2Dealer.background:SetPoint("CENTER", rulesFrame2Dealer, 23, 2)
rulesFrame2Dealer.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Rules.tga")
rulesFrame2Dealer.background:SetBlendMode("BLEND")
rulesFrame2Dealer.background:SetDrawLayer("ARTWORK")

rulesFrame2Dealer.returnButton = CreateFrame("Button", nil, rulesFrame2Dealer, "GameMenuButtonTemplate")
rulesFrame2Dealer.returnButton:SetPoint("TOPLEFT", rulesFrame2Dealer, 15, -35)
rulesFrame2Dealer.returnButton:SetSize(70, 25)
rulesFrame2Dealer.returnButton:SetText("Return")
rulesFrame2Dealer.returnButton:SetNormalFontObject("GameFontWhiteSmall")
rulesFrame2Dealer.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

rulesFrame2Dealer.nextPageButton = CreateFrame("Button", nil, rulesFrame2Dealer, "GameMenuButtonTemplate")
rulesFrame2Dealer.nextPageButton:SetPoint("BOTTOMRIGHT", rulesFrame2Dealer, -113, 53)
rulesFrame2Dealer.nextPageButton:SetSize(110, 25)
rulesFrame2Dealer.nextPageButton:SetText("Next Page >")
rulesFrame2Dealer.nextPageButton:SetNormalFontObject("GameFontWhiteSmall")
rulesFrame2Dealer.nextPageButton:SetHighlightFontObject("GameFontWhiteSmall")

rulesFrame2Dealer.step1 = rulesFrame2Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2Dealer.step1:SetPoint("TOPLEFT", rulesFrame2Dealer, 110, -110)
rulesFrame2Dealer.step1:SetText("1. Card Values")
rulesFrame2Dealer.step1:SetJustifyH("LEFT")
rulesFrame2Dealer.step1:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame2Dealer.step1:SetTextColor(1, 0.882, 0.596)

rulesFrame2Dealer.step1a = rulesFrame2Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2Dealer.step1a:SetPoint("TOPLEFT", rulesFrame2Dealer, 120, -130)
rulesFrame2Dealer.step1a:SetText("• Number cards (2-10) are worth their face value\n• Face cards (Jack, Queen, King) are each worth 10 points\n• Aces can be worth either 1 or 11 points")
rulesFrame2Dealer.step1a:SetJustifyH("LEFT")
rulesFrame2Dealer.step1a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame2Dealer.step1b = rulesFrame2Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2Dealer.step1b:SetPoint("TOPLEFT", rulesFrame2Dealer, 130, -223)
rulesFrame2Dealer.step1b:SetText("7        10     1/11")
rulesFrame2Dealer.step1b:SetJustifyH("LEFT")
rulesFrame2Dealer.step1b:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")

rulesFrame2Dealer.step2 = rulesFrame2Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2Dealer.step2:SetPoint("TOPLEFT", rulesFrame2Dealer, 110, -245)
rulesFrame2Dealer.step2:SetText("2. Starting the Game")
rulesFrame2Dealer.step2:SetJustifyH("LEFT")
rulesFrame2Dealer.step2:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame2Dealer.step2:SetTextColor(1, 0.882, 0.596)

rulesFrame2Dealer.step2a = rulesFrame2Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2Dealer.step2a:SetPoint("TOPLEFT", rulesFrame2Dealer, 120, -265)
rulesFrame2Dealer.step2a:SetText("• All Player's must place their bets (within the table limits) before the round\nbegins and the cards are dealt\n• Each Player will receive two cards whilst the Dealer only receives one card\n(known as the 'upcard')")
rulesFrame2Dealer.step2a:SetJustifyH("LEFT")
rulesFrame2Dealer.step2a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame2Dealer.step3 = rulesFrame2Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2Dealer.step3:SetPoint("TOPLEFT", rulesFrame2Dealer, 110, -310)
rulesFrame2Dealer.step3:SetText("3. Player's Turn")
rulesFrame2Dealer.step3:SetJustifyH("LEFT")
rulesFrame2Dealer.step3:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame2Dealer.step3:SetTextColor(1, 0.882, 0.596)

rulesFrame2Dealer.step3a = rulesFrame2Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2Dealer.step3a:SetPoint("TOPLEFT", rulesFrame2Dealer, 120, -330)
rulesFrame2Dealer.step3a:SetText("• On your turn, you must make one of the following decisions:\n\n          HIT  -  you want another card\n          STAND  -  you do not want any more cards\n          DOUBLE  -  you want to double your bet and receive one more card\n          SPLIT  -  you want to split your cards into two separate hands")
rulesFrame2Dealer.step3a:SetJustifyH("LEFT")
rulesFrame2Dealer.step3a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame2Dealer.page1 = rulesFrame2Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame2Dealer.page1:SetPoint("BOTTOM", rulesFrame2Dealer, 0, 57)
rulesFrame2Dealer.page1:SetText("PAGE 1")
rulesFrame2Dealer.page1:SetJustifyH("CENTER")
rulesFrame2Dealer.page1:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
rulesFrame2Dealer.page1:SetTextColor(1, 0.882, 0.596)

-- Enable click-and-drag functionality
rulesFrame2Dealer:SetMovable(true)
rulesFrame2Dealer:EnableMouse(true)
rulesFrame2Dealer:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
rulesFrame2Dealer:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

rulesFrame2Dealer:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)

-- Create a frame for the test screen
rulesFrame3Dealer = CreateFrame("Frame", "BlackjackRules3Frame", UIParent, "BasicFrameTemplateWithInset")
rulesFrame3Dealer:SetSize(640, 475)
rulesFrame3Dealer:SetPoint("CENTER")
rulesFrame3Dealer:SetFrameStrata("HIGH")
rulesFrame3Dealer:SetFrameLevel(rulesFrame3Dealer:GetFrameLevel() + 100)
rulesFrame3Dealer:Hide()

-- Add a title to the test frame
rulesFrame3Dealer.title = rulesFrame3Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3Dealer.title:SetPoint("TOP", rulesFrame3Dealer, 0, -5)
rulesFrame3Dealer.title:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

rulesFrame3Dealer.background = rulesFrame3Dealer:CreateTexture(nil, "OVERLAY")
rulesFrame3Dealer.background:SetSize(1364, 682)
rulesFrame3Dealer.background:SetPoint("CENTER", rulesFrame3Dealer, 23, 2)
rulesFrame3Dealer.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Rules2.tga")
rulesFrame3Dealer.background:SetBlendMode("BLEND")
rulesFrame3Dealer.background:SetDrawLayer("ARTWORK")

rulesFrame3Dealer.returnButton = CreateFrame("Button", nil, rulesFrame3Dealer, "GameMenuButtonTemplate")
rulesFrame3Dealer.returnButton:SetPoint("TOPLEFT", rulesFrame3Dealer, 15, -35)
rulesFrame3Dealer.returnButton:SetSize(70, 25)
rulesFrame3Dealer.returnButton:SetText("Return")
rulesFrame3Dealer.returnButton:SetNormalFontObject("GameFontWhiteSmall")
rulesFrame3Dealer.returnButton:SetHighlightFontObject("GameFontWhiteSmall")

rulesFrame3Dealer.previousPageButton = CreateFrame("Button", nil, rulesFrame3Dealer, "GameMenuButtonTemplate")
rulesFrame3Dealer.previousPageButton:SetPoint("BOTTOMLEFT", rulesFrame3Dealer, 113, 53)
rulesFrame3Dealer.previousPageButton:SetSize(110, 25)
rulesFrame3Dealer.previousPageButton:SetText("< Previous Page")
rulesFrame3Dealer.previousPageButton:SetNormalFontObject("GameFontWhiteSmall")
rulesFrame3Dealer.previousPageButton:SetHighlightFontObject("GameFontWhiteSmall")

rulesFrame3Dealer.step3b = rulesFrame3Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3Dealer.step3b:SetPoint("TOPLEFT", rulesFrame3Dealer, 120, -75)
rulesFrame3Dealer.step3b:SetText("• If the Dealer's upcard is an Ace you will be offered 'Insurance'\n\n          INSURANCE  -  you place an additional bet (half of your main bet) which\n                                  pays out at 2:1 only if the Dealer gets Blackjack\n\n          For example, you place a 200G main bet and the Dealer has an Ace.\n          You decide to place a 100G insurance bet and the Dealer gets Blackjack.\n          You lose your 200G main bet but you win 300G back from insurance,\n          allowing you to escape a Dealer Blackjack without losing anything.")
rulesFrame3Dealer.step3b:SetJustifyH("LEFT")
rulesFrame3Dealer.step3b:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame3Dealer.step4 = rulesFrame3Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3Dealer.step4:SetPoint("TOPLEFT", rulesFrame3Dealer, 110, -170)
rulesFrame3Dealer.step4:SetText("4. Dealer's Turn")
rulesFrame3Dealer.step4:SetJustifyH("LEFT")
rulesFrame3Dealer.step4:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame3Dealer.step4:SetTextColor(1, 0.882, 0.596)

rulesFrame3Dealer.step4a = rulesFrame3Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3Dealer.step4a:SetPoint("TOPLEFT", rulesFrame3Dealer, 120, -190)
rulesFrame3Dealer.step4a:SetText("• Once all Player's have finished their turn, the Dealer will begin their turn\n• The Dealer must continue to HIT until their hand totals 17 or higher")
rulesFrame3Dealer.step4a:SetJustifyH("LEFT")
rulesFrame3Dealer.step4a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame3Dealer.step5 = rulesFrame3Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3Dealer.step5:SetPoint("TOPLEFT", rulesFrame3Dealer, 110, -220)
rulesFrame3Dealer.step5:SetText("5. Blackjack")
rulesFrame3Dealer.step5:SetJustifyH("LEFT")
rulesFrame3Dealer.step5:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame3Dealer.step5:SetTextColor(1, 0.882, 0.596)

rulesFrame3Dealer.step5a = rulesFrame3Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3Dealer.step5a:SetPoint("TOPLEFT", rulesFrame3Dealer, 120, -240)
rulesFrame3Dealer.step5a:SetText("• 'Blackjack' is a special hand consisting of an Ace and any 10-point card\n• It pays out at 3:2 instead of a regular 1:1 win")
rulesFrame3Dealer.step5a:SetJustifyH("LEFT")
rulesFrame3Dealer.step5a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame3Dealer.step6 = rulesFrame3Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3Dealer.step6:SetPoint("TOPLEFT", rulesFrame3Dealer, 110, -270)
rulesFrame3Dealer.step6:SetText("6. Final Result")
rulesFrame3Dealer.step6:SetJustifyH("LEFT")
rulesFrame3Dealer.step6:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
rulesFrame3Dealer.step6:SetTextColor(1, 0.882, 0.596)

rulesFrame3Dealer.step6a = rulesFrame3Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3Dealer.step6a:SetPoint("TOPLEFT", rulesFrame3Dealer, 120, -290)
rulesFrame3Dealer.step6a:SetText("WIN\n          • If your hand is closer to 21 (without going over) than the Dealer\n          • If you have Blackjack and the Dealer's upcard is not an Ace or 10\n          • If the Dealer busts (goes over 21)\nPUSH\n          • If you and the Dealer have the same hand value, your bet is returned\nLOSS\n          • If your hand is lower than the Dealer (without going over 21)\n          • If you go bust (you took too many cards and went above 21)")
rulesFrame3Dealer.step6a:SetJustifyH("LEFT")
rulesFrame3Dealer.step6a:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

rulesFrame3Dealer.page2 = rulesFrame3Dealer:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
rulesFrame3Dealer.page2:SetPoint("BOTTOM", rulesFrame3Dealer, 0, 57)
rulesFrame3Dealer.page2:SetText("PAGE 2")
rulesFrame3Dealer.page2:SetJustifyH("CENTER")
rulesFrame3Dealer.page2:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
rulesFrame3Dealer.page2:SetTextColor(1, 0.882, 0.596)

-- Enable click-and-drag functionality
rulesFrame3Dealer:SetMovable(true)
rulesFrame3Dealer:EnableMouse(true)
rulesFrame3Dealer:RegisterForDrag("LeftButton")

-- Set the frame's script for handling the drag
rulesFrame3Dealer:SetScript("OnDragStart", function(self)
    self:StartMoving()
end)

rulesFrame3Dealer:SetScript("OnDragStop", function(self)
    self:StopMovingOrSizing()
end)




-- Resets dealerFrame to the center of the screen upon reload/login
function ResetFramePosition()
    playerFrame:ClearAllPoints()
    playerFrame:SetPoint("CENTER", 0, 0)
    launchFrame:ClearAllPoints()
    launchFrame:SetPoint("CENTER", 0, 0)
    launchFrame2:ClearAllPoints()
    launchFrame2:SetPoint("CENTER", 0, 0)
    tutorialFrame:ClearAllPoints()
    tutorialFrame:SetPoint("CENTER", 0, 0)
    tutorialFrame2:ClearAllPoints()
    tutorialFrame2:SetPoint("CENTER", 0, 0)
    tutorialFrame3:ClearAllPoints()
    tutorialFrame3:SetPoint("CENTER", 0, 0)
    faqsFrame:ClearAllPoints()
    faqsFrame:SetPoint("CENTER", 0, 0)
    rulesFrame2:ClearAllPoints()
    rulesFrame2:SetPoint("CENTER", 0, 0)
    rulesFrame3:ClearAllPoints()
    rulesFrame3:SetPoint("CENTER", 0, 0)
    tutorialFrameDealer:ClearAllPoints()
    tutorialFrameDealer:SetPoint("CENTER", 0, 0)
    tutorialFrameDealer2:ClearAllPoints()
    tutorialFrameDealer2:SetPoint("CENTER", 0, 0)
    tutorialFrameDealer3:ClearAllPoints()
    tutorialFrameDealer3:SetPoint("CENTER", 0, 0)
    faqsFrameDealer:ClearAllPoints()
    faqsFrameDealer:SetPoint("CENTER", 0, 0)
    rulesFrame2Dealer:ClearAllPoints()
    rulesFrame2Dealer:SetPoint("CENTER", 0, 0)
    rulesFrame3Dealer:ClearAllPoints()
    rulesFrame3Dealer:SetPoint("CENTER", 0, 0)
end

local function OnEvent(self, event, ...)
    if event == "PLAYER_LOGIN" then
        DEFAULT_CHAT_FRAME:AddMessage("Blackjack v5.0.2 by Hyrav has loaded. Type /blackjack to play!", 1, 0.129, 0.898)
    end
end

frame = CreateFrame("Frame")
frame:RegisterEvent("PLAYER_LOGIN")
frame:SetScript("OnEvent", ResetFramePosition)
frame:SetScript("OnEvent", OnEvent)




















-- Function to enable the "Join Table" button
function EnableJoinButton()
    cashDeskFrame.returnButton:Enable()
    launchFrame2.tableStatus:SetText("Table: Open")
    launchFrame2.joinButton:Enable()
end






























-- >> PRELOAD WINDOW <<
-- >> PRELOAD WINDOW <<
-- >> PRELOAD WINDOW <<

-- Rebet window
preloadFrame = CreateFrame("Frame", "BlackjackPreloadFrame", UIParent, "InsetFrameTemplate")
preloadFrame:SetSize(170, 140)
preloadFrame:SetPoint("TOPRIGHT", playerFrame, -118, -43)
preloadFrame:SetFrameStrata("TOOLTIP")
preloadFrame:Hide()
-- Setting a title
preloadFrame.title = preloadFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
preloadFrame.title:SetPoint("TOP", preloadFrame, 0, -7)
preloadFrame.title:SetText("Preload Bets")
-- Main Bet Text
preloadFrame.preloadMainBetText = preloadFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
preloadFrame.preloadMainBetText:SetPoint("LEFT", preloadFrame, 12, 30)
preloadFrame.preloadMainBetText:SetJustifyH("LEFT")
preloadFrame.preloadMainBetText:SetText("Main Bet:")
preloadFrame.preloadMainBetText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
preloadFrame.preloadMainBetText:Hide()
-- PP Side Bet Text
preloadFrame.preloadPPBetText = preloadFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
preloadFrame.preloadPPBetText:SetPoint("LEFT", preloadFrame, 12, 8)
preloadFrame.preloadPPBetText:SetJustifyH("LEFT")
preloadFrame.preloadPPBetText:SetText("PP Side Bet:")
preloadFrame.preloadPPBetText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
preloadFrame.preloadPPBetText:Hide()
-- PP Side Bet Text
preloadFrame.preload213BetText = preloadFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
preloadFrame.preload213BetText:SetPoint("LEFT", preloadFrame, 12, -14)
preloadFrame.preload213BetText:SetJustifyH("LEFT")
preloadFrame.preload213BetText:SetText("21+3 Side Bet:")
preloadFrame.preload213BetText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
preloadFrame.preload213BetText:Hide()

-- Wagers for Player 1
-- Main Bet
player1PreloadEditBoxMainBet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player1PreloadEditBoxMainBet:SetSize(55, 30)
player1PreloadEditBoxMainBet:SetPoint("LEFT", preloadFrame, 102, 30)
player1PreloadEditBoxMainBet:SetAutoFocus(false)
player1PreloadEditBoxMainBet:SetNumeric(true)
player1PreloadEditBoxMainBet:Hide()
-- Perfect Pairs
player1PreloadEditBoxPPBet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player1PreloadEditBoxPPBet:SetSize(35, 30)
player1PreloadEditBoxPPBet:SetPoint("LEFT", preloadFrame, 121, 8)
player1PreloadEditBoxPPBet:SetAutoFocus(false)
player1PreloadEditBoxPPBet:SetNumeric(true)
player1PreloadEditBoxPPBet:Hide()
-- 21+3
player1PreloadEditBox213Bet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player1PreloadEditBox213Bet:SetSize(35, 30)
player1PreloadEditBox213Bet:SetPoint("LEFT", preloadFrame, 121, -14)
player1PreloadEditBox213Bet:SetAutoFocus(false)
player1PreloadEditBox213Bet:SetNumeric(true)
player1PreloadEditBox213Bet:Hide()
-- Player 1 Preload Bet button
player1PreloadBetButton = CreateFrame("Button", nil, preloadFrame, "GameMenuButtonTemplate")
player1PreloadBetButton:SetPoint("BOTTOM", preloadFrame, 1, 13)
player1PreloadBetButton:SetSize(85, 25)
player1PreloadBetButton:SetText("Bet All")
player1PreloadBetButton:Hide()

-- Wagers for Player 2
-- Main Bet
player2PreloadEditBoxMainBet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player2PreloadEditBoxMainBet:SetSize(55, 30)
player2PreloadEditBoxMainBet:SetPoint("LEFT", preloadFrame, 102, 30)
player2PreloadEditBoxMainBet:SetAutoFocus(false)
player2PreloadEditBoxMainBet:SetNumeric(true)
player2PreloadEditBoxMainBet:Hide()
-- Perfect Pairs
player2PreloadEditBoxPPBet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player2PreloadEditBoxPPBet:SetSize(35, 30)
player2PreloadEditBoxPPBet:SetPoint("LEFT", preloadFrame, 121, 8)
player2PreloadEditBoxPPBet:SetAutoFocus(false)
player2PreloadEditBoxPPBet:SetNumeric(true)
player2PreloadEditBoxPPBet:Hide()
-- 21+3
player2PreloadEditBox213Bet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player2PreloadEditBox213Bet:SetSize(35, 30)
player2PreloadEditBox213Bet:SetPoint("LEFT", preloadFrame, 121, -14)
player2PreloadEditBox213Bet:SetAutoFocus(false)
player2PreloadEditBox213Bet:SetNumeric(true)
player2PreloadEditBox213Bet:Hide()
-- Player 2 Preload Bet button
player2PreloadBetButton = CreateFrame("Button", nil, preloadFrame, "GameMenuButtonTemplate")
player2PreloadBetButton:SetPoint("BOTTOM", preloadFrame, 1, 13)
player2PreloadBetButton:SetSize(85, 25)
player2PreloadBetButton:SetText("Bet All")
player2PreloadBetButton:Hide()

-- Wagers for Player 3
-- Main Bet
player3PreloadEditBoxMainBet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player3PreloadEditBoxMainBet:SetSize(55, 30)
player3PreloadEditBoxMainBet:SetPoint("LEFT", preloadFrame, 102, 30)
player3PreloadEditBoxMainBet:SetAutoFocus(false)
player3PreloadEditBoxMainBet:SetNumeric(true)
player3PreloadEditBoxMainBet:Hide()
-- Perfect Pairs
player3PreloadEditBoxPPBet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player3PreloadEditBoxPPBet:SetSize(35, 30)
player3PreloadEditBoxPPBet:SetPoint("LEFT", preloadFrame, 121, 8)
player3PreloadEditBoxPPBet:SetAutoFocus(false)
player3PreloadEditBoxPPBet:SetNumeric(true)
player3PreloadEditBoxPPBet:Hide()
-- 21+3
player3PreloadEditBox213Bet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player3PreloadEditBox213Bet:SetSize(35, 30)
player3PreloadEditBox213Bet:SetPoint("LEFT", preloadFrame, 121, -14)
player3PreloadEditBox213Bet:SetAutoFocus(false)
player3PreloadEditBox213Bet:SetNumeric(true)
player3PreloadEditBox213Bet:Hide()
-- Player 2 Preload Bet button
player3PreloadBetButton = CreateFrame("Button", nil, preloadFrame, "GameMenuButtonTemplate")
player3PreloadBetButton:SetPoint("BOTTOM", preloadFrame, 1, 13)
player3PreloadBetButton:SetSize(85, 25)
player3PreloadBetButton:SetText("Bet All")
player3PreloadBetButton:Hide()

-- Wagers for Player 4
-- Main Bet
player4PreloadEditBoxMainBet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player4PreloadEditBoxMainBet:SetSize(55, 30)
player4PreloadEditBoxMainBet:SetPoint("LEFT", preloadFrame, 102, 30)
player4PreloadEditBoxMainBet:SetAutoFocus(false)
player4PreloadEditBoxMainBet:SetNumeric(true)
player4PreloadEditBoxMainBet:Hide()
-- Perfect Pairs
player4PreloadEditBoxPPBet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player4PreloadEditBoxPPBet:SetSize(35, 30)
player4PreloadEditBoxPPBet:SetPoint("LEFT", preloadFrame, 121, 8)
player4PreloadEditBoxPPBet:SetAutoFocus(false)
player4PreloadEditBoxPPBet:SetNumeric(true)
player4PreloadEditBoxPPBet:Hide()
-- 21+3
player4PreloadEditBox213Bet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player4PreloadEditBox213Bet:SetSize(35, 30)
player4PreloadEditBox213Bet:SetPoint("LEFT", preloadFrame, 121, -14)
player4PreloadEditBox213Bet:SetAutoFocus(false)
player4PreloadEditBox213Bet:SetNumeric(true)
player4PreloadEditBox213Bet:Hide()
-- Player 2 Preload Bet button
player4PreloadBetButton = CreateFrame("Button", nil, preloadFrame, "GameMenuButtonTemplate")
player4PreloadBetButton:SetPoint("BOTTOM", preloadFrame, 1, 13)
player4PreloadBetButton:SetSize(85, 25)
player4PreloadBetButton:SetText("Bet All")
player4PreloadBetButton:Hide()

-- Wagers for Player 5
-- Main Bet
player5PreloadEditBoxMainBet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player5PreloadEditBoxMainBet:SetSize(55, 30)
player5PreloadEditBoxMainBet:SetPoint("LEFT", preloadFrame, 102, 30)
player5PreloadEditBoxMainBet:SetAutoFocus(false)
player5PreloadEditBoxMainBet:SetNumeric(true)
player5PreloadEditBoxMainBet:Hide()
-- Perfect Pairs
player5PreloadEditBoxPPBet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player5PreloadEditBoxPPBet:SetSize(35, 30)
player5PreloadEditBoxPPBet:SetPoint("LEFT", preloadFrame, 121, 8)
player5PreloadEditBoxPPBet:SetAutoFocus(false)
player5PreloadEditBoxPPBet:SetNumeric(true)
player5PreloadEditBoxPPBet:Hide()
-- 21+3
player5PreloadEditBox213Bet = CreateFrame("EditBox", nil, preloadFrame, "InputBoxTemplate")
player5PreloadEditBox213Bet:SetSize(35, 30)
player5PreloadEditBox213Bet:SetPoint("LEFT", preloadFrame, 121, -14)
player5PreloadEditBox213Bet:SetAutoFocus(false)
player5PreloadEditBox213Bet:SetNumeric(true)
player5PreloadEditBox213Bet:Hide()
-- Player 2 Preload Bet button
player5PreloadBetButton = CreateFrame("Button", nil, preloadFrame, "GameMenuButtonTemplate")
player5PreloadBetButton:SetPoint("BOTTOM", preloadFrame, 1, 13)
player5PreloadBetButton:SetSize(85, 25)
player5PreloadBetButton:SetText("Bet All")
player5PreloadBetButton:Hide()
























-- >> HISTORY WINDOW <<
-- >> HISTORY WINDOW <<
-- >> HISTORY WINDOW <<

-- History window
historyFrame = CreateFrame("Frame", "BlackjackHistoryFrame", UIParent, "InsetFrameTemplate")
historyFrame:SetSize(246, 105)
historyFrame:SetPoint("TOP", playerFrame, 2, -26)
historyFrame:SetFrameStrata("HIGH")
historyFrame:SetFrameLevel(8)
historyFrame:Hide()

-- Setting a title
historyFrame.title = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.title:SetPoint("TOP", historyFrame, 0, -9)
historyFrame.title:SetText("Profit/Loss")

-- Total Wagered Text
historyFrame.totalWageredText = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.totalWageredText:SetPoint("CENTER", historyFrame, -42, 12)
historyFrame.totalWageredText:SetJustifyH("RIGHT")
historyFrame.totalWageredText:SetText("Total Wagered:")
historyFrame.totalWageredText:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.totalWageredText:Hide()

-- Total Wagered Amount
historyFrame.player1totalWageredAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player1totalWageredAmount:SetPoint("CENTER", historyFrame, 40, 12)
historyFrame.player1totalWageredAmount:SetJustifyH("LEFT")
historyFrame.player1totalWageredAmount:SetText("0 G")
historyFrame.player1totalWageredAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player1totalWageredAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player1totalWageredAmount:Hide()

historyFrame.player2totalWageredAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player2totalWageredAmount:SetPoint("CENTER", historyFrame, 40, 12)
historyFrame.player2totalWageredAmount:SetJustifyH("LEFT")
historyFrame.player2totalWageredAmount:SetText("0 G")
historyFrame.player2totalWageredAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player2totalWageredAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player2totalWageredAmount:Hide()

historyFrame.player3totalWageredAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player3totalWageredAmount:SetPoint("CENTER", historyFrame, 40, 12)
historyFrame.player3totalWageredAmount:SetJustifyH("LEFT")
historyFrame.player3totalWageredAmount:SetText("0 G")
historyFrame.player3totalWageredAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player3totalWageredAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player3totalWageredAmount:Hide()

historyFrame.player4totalWageredAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player4totalWageredAmount:SetPoint("CENTER", historyFrame, 40, 12)
historyFrame.player4totalWageredAmount:SetJustifyH("LEFT")
historyFrame.player4totalWageredAmount:SetText("0 G")
historyFrame.player4totalWageredAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player4totalWageredAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player4totalWageredAmount:Hide()

historyFrame.player5totalWageredAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player5totalWageredAmount:SetPoint("CENTER", historyFrame, 40, 12)
historyFrame.player5totalWageredAmount:SetJustifyH("LEFT")
historyFrame.player5totalWageredAmount:SetText("0 G")
historyFrame.player5totalWageredAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player5totalWageredAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player5totalWageredAmount:Hide()

-- Total Won Text
historyFrame.totalWonText = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.totalWonText:SetPoint("CENTER", historyFrame, -30, -3)
historyFrame.totalWonText:SetJustifyH("RIGHT")
historyFrame.totalWonText:SetText("Total Won:")
historyFrame.totalWonText:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.totalWonText:Hide()

-- Total Won Amount
historyFrame.player1totalWonAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player1totalWonAmount:SetPoint("CENTER", historyFrame, 40, -3)
historyFrame.player1totalWonAmount:SetJustifyH("LEFT")
historyFrame.player1totalWonAmount:SetText("0 G")
historyFrame.player1totalWonAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player1totalWonAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player1totalWonAmount:Hide()

historyFrame.player2totalWonAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player2totalWonAmount:SetPoint("CENTER", historyFrame, 40, -3)
historyFrame.player2totalWonAmount:SetJustifyH("LEFT")
historyFrame.player2totalWonAmount:SetText("0 G")
historyFrame.player2totalWonAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player2totalWonAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player2totalWonAmount:Hide()

historyFrame.player3totalWonAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player3totalWonAmount:SetPoint("CENTER", historyFrame, 40, -3)
historyFrame.player3totalWonAmount:SetJustifyH("LEFT")
historyFrame.player3totalWonAmount:SetText("0 G")
historyFrame.player3totalWonAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player3totalWonAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player3totalWonAmount:Hide()

historyFrame.player4totalWonAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player4totalWonAmount:SetPoint("CENTER", historyFrame, 40, -3)
historyFrame.player4totalWonAmount:SetJustifyH("LEFT")
historyFrame.player4totalWonAmount:SetText("0 G")
historyFrame.player4totalWonAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player4totalWonAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player4totalWonAmount:Hide()

historyFrame.player5totalWonAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player5totalWonAmount:SetPoint("CENTER", historyFrame, 40, -3)
historyFrame.player5totalWonAmount:SetJustifyH("LEFT")
historyFrame.player5totalWonAmount:SetText("0 G")
historyFrame.player5totalWonAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player5totalWonAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player5totalWonAmount:Hide()

-- Total Lost Text
historyFrame.totalLostText = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.totalLostText:SetPoint("CENTER", historyFrame, -28, -18)
historyFrame.totalLostText:SetJustifyH("RIGHT")
historyFrame.totalLostText:SetText("Total Lost:")
historyFrame.totalLostText:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.totalLostText:Hide()

-- Total Lost Amount
historyFrame.player1totalLostAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player1totalLostAmount:SetPoint("CENTER", historyFrame, 40, -18)
historyFrame.player1totalLostAmount:SetJustifyH("LEFT")
historyFrame.player1totalLostAmount:SetText("0 G")
historyFrame.player1totalLostAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player1totalLostAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player1totalLostAmount:Hide()

historyFrame.player2totalLostAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player2totalLostAmount:SetPoint("CENTER", historyFrame, 40, -18)
historyFrame.player2totalLostAmount:SetJustifyH("LEFT")
historyFrame.player2totalLostAmount:SetText("0 G")
historyFrame.player2totalLostAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player2totalLostAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player2totalLostAmount:Hide()

historyFrame.player3totalLostAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player3totalLostAmount:SetPoint("CENTER", historyFrame, 40, -18)
historyFrame.player3totalLostAmount:SetJustifyH("LEFT")
historyFrame.player3totalLostAmount:SetText("0 G")
historyFrame.player3totalLostAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player3totalLostAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player3totalLostAmount:Hide()

historyFrame.player4totalLostAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player4totalLostAmount:SetPoint("CENTER", historyFrame, 40, -18)
historyFrame.player4totalLostAmount:SetJustifyH("LEFT")
historyFrame.player4totalLostAmount:SetText("0 G")
historyFrame.player4totalLostAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player4totalLostAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player4totalLostAmount:Hide()

historyFrame.player5totalLostAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player5totalLostAmount:SetPoint("CENTER", historyFrame, 40, -18)
historyFrame.player5totalLostAmount:SetJustifyH("LEFT")
historyFrame.player5totalLostAmount:SetText("0 G")
historyFrame.player5totalLostAmount:SetTextColor(1, 0.98, 0.557)
historyFrame.player5totalLostAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player5totalLostAmount:Hide()

-- Profit Text
historyFrame.ProfitText = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.ProfitText:SetPoint("CENTER", historyFrame, -16, -33)
historyFrame.ProfitText:SetJustifyH("RIGHT")
historyFrame.ProfitText:SetText("Profit:")
historyFrame.ProfitText:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.ProfitText:Hide()

-- Total Profit Amount
historyFrame.player1ProfitAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player1ProfitAmount:SetPoint("CENTER", historyFrame, 40, -33)
historyFrame.player1ProfitAmount:SetJustifyH("LEFT")
historyFrame.player1ProfitAmount:SetText("0 G")
historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
historyFrame.player1ProfitAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player1ProfitAmount:Hide()

historyFrame.player2ProfitAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player2ProfitAmount:SetPoint("CENTER", historyFrame, 40, -33)
historyFrame.player2ProfitAmount:SetJustifyH("LEFT")
historyFrame.player2ProfitAmount:SetText("0 G")
historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
historyFrame.player2ProfitAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player2ProfitAmount:Hide()

historyFrame.player3ProfitAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player3ProfitAmount:SetPoint("CENTER", historyFrame, 40, -33)
historyFrame.player3ProfitAmount:SetJustifyH("LEFT")
historyFrame.player3ProfitAmount:SetText("0 G")
historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
historyFrame.player3ProfitAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player3ProfitAmount:Hide()

historyFrame.player4ProfitAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player4ProfitAmount:SetPoint("CENTER", historyFrame, 40, -33)
historyFrame.player4ProfitAmount:SetJustifyH("LEFT")
historyFrame.player4ProfitAmount:SetText("0 G")
historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
historyFrame.player4ProfitAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player4ProfitAmount:Hide()

historyFrame.player5ProfitAmount = historyFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
historyFrame.player5ProfitAmount:SetPoint("CENTER", historyFrame, 40, -33)
historyFrame.player5ProfitAmount:SetJustifyH("LEFT")
historyFrame.player5ProfitAmount:SetText("0 G")
historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
historyFrame.player5ProfitAmount:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
historyFrame.player5ProfitAmount:Hide()



















-- >> PAYOUTS WINDOW <<
-- >> PAYOUTS WINDOW <<
-- >> PAYOUTS WINDOW <<

-- Payouts window
-- Creating the payoutsFrame
payoutsFrame = CreateFrame("Frame", "BlackjackPayoutsFrame", UIParent, "BasicFrameTemplateWithInset")
payoutsFrame:SetSize(275, 720)
payoutsFrame:SetPoint("LEFT", playerFrame, 0, 0)
payoutsFrame:SetFrameStrata("TOOLTIP")
payoutsFrame:SetFrameLevel(payoutsFrame:GetFrameLevel() + 200)
payoutsFrame:Hide()

-- Setting a title
payoutsFrame.title = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.title:SetPoint("TOP", payoutsFrame, 0, -5)
payoutsFrame.title:SetText("Payouts")

-- Headings
-- Main Bets
payoutsFrame.mainBetsTitle = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.mainBetsTitle:SetPoint("TOPLEFT", payoutsFrame, 15, -36)
payoutsFrame.mainBetsTitle:SetJustifyH("LEFT")
payoutsFrame.mainBetsTitle:SetText("Main Bets")
payoutsFrame.mainBetsTitle:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.mainBetsTitle:SetTextColor(1, 0, 0)
payoutsFrame.mainBetsTitle:Hide()
-- Side Bets
payoutsFrame.sideBetsTitle = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.sideBetsTitle:SetPoint("TOPLEFT", payoutsFrame, 15, -135)
payoutsFrame.sideBetsTitle:SetJustifyH("LEFT")
payoutsFrame.sideBetsTitle:SetText("Side Bets")
payoutsFrame.sideBetsTitle:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.sideBetsTitle:SetTextColor(1, 0, 0)
payoutsFrame.sideBetsTitle:Hide()
-- Perfect Pairs
payoutsFrame.perfectPairsTitle = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.perfectPairsTitle:SetPoint("TOPLEFT", payoutsFrame, 15, -155)
payoutsFrame.perfectPairsTitle:SetJustifyH("LEFT")
payoutsFrame.perfectPairsTitle:SetText("Perfect Pairs (PP)")
payoutsFrame.perfectPairsTitle:SetTextColor(1, 0.298, 0.298)
payoutsFrame.perfectPairsTitle:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
payoutsFrame.perfectPairsTitle:Hide()
-- Perfect Pairs (explain)
payoutsFrame.perfectPairsExplain = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.perfectPairsExplain:SetPoint("TOPLEFT", payoutsFrame, 152, -156)
payoutsFrame.perfectPairsExplain:SetJustifyH("LEFT")
payoutsFrame.perfectPairsExplain:SetText("(Player's 2 Cards)")
payoutsFrame.perfectPairsExplain:SetTextColor(1, 0.298, 0.298)
payoutsFrame.perfectPairsExplain:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
payoutsFrame.perfectPairsExplain:Hide()
-- 21+3
payoutsFrame.t213Title = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.t213Title:SetPoint("TOPLEFT", payoutsFrame, 15, -325)
payoutsFrame.t213Title:SetJustifyH("LEFT")
payoutsFrame.t213Title:SetText("21+3")
payoutsFrame.t213Title:SetTextColor(1, 0.298, 0.298)
payoutsFrame.t213Title:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
payoutsFrame.t213Title:Hide()
-- 21+3 (explain)
payoutsFrame.t213Explain = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.t213Explain:SetPoint("TOPLEFT", payoutsFrame, 62, -327)
payoutsFrame.t213Explain:SetJustifyH("LEFT")
payoutsFrame.t213Explain:SetText("(Player's 2 Cards + Dealer's Upcard)")
payoutsFrame.t213Explain:SetTextColor(1, 0.298, 0.298)
payoutsFrame.t213Explain:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
payoutsFrame.t213Explain:Hide()
-- 21+3 (explain) 2
payoutsFrame.t213Explain2 = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.t213Explain2:SetPoint("TOPLEFT", payoutsFrame, 198, -370)
payoutsFrame.t213Explain2:SetJustifyH("RIGHT")
payoutsFrame.t213Explain2:SetText("Any Card\n\nSame Suit")
payoutsFrame.t213Explain2:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
payoutsFrame.t213Explain2:Hide()
-- 21+3 (explain) 3
payoutsFrame.t213Explain3 = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.t213Explain3:SetPoint("TOPLEFT", payoutsFrame, 176, -444)
payoutsFrame.t213Explain3:SetJustifyH("RIGHT")
payoutsFrame.t213Explain3:SetText("Numeric Order\n\nAny Suit")
payoutsFrame.t213Explain3:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
payoutsFrame.t213Explain3:Hide()
-- 21+3 (explain) 4
payoutsFrame.t213Explain4 = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.t213Explain4:SetPoint("TOPLEFT", payoutsFrame, 198, -519)
payoutsFrame.t213Explain4:SetJustifyH("RIGHT")
payoutsFrame.t213Explain4:SetText("Same Card\n\nAny Suit")
payoutsFrame.t213Explain4:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
payoutsFrame.t213Explain4:Hide()
-- 21+3 (explain) 5
payoutsFrame.t213Explain5 = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.t213Explain5:SetPoint("TOPLEFT", payoutsFrame, 176, -589)
payoutsFrame.t213Explain5:SetJustifyH("RIGHT")
payoutsFrame.t213Explain5:SetText("Numeric Order\n\nSame Suit")
payoutsFrame.t213Explain5:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
payoutsFrame.t213Explain5:Hide()
-- 21+3 (explain) 6
payoutsFrame.t213Explain6 = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.t213Explain6:SetPoint("TOPLEFT", payoutsFrame, 198, -663)
payoutsFrame.t213Explain6:SetJustifyH("RIGHT")
payoutsFrame.t213Explain6:SetText("Same Card\n\nSame Suit")
payoutsFrame.t213Explain6:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
payoutsFrame.t213Explain6:Hide()

-- Subheadings and Payouts
-- Standard
payoutsFrame.mainBetStandard = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.mainBetStandard:SetPoint("TOPLEFT", payoutsFrame, 15, -60)
payoutsFrame.mainBetStandard:SetJustifyH("LEFT")
payoutsFrame.mainBetStandard:SetText("Standard")
payoutsFrame.mainBetStandard:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
payoutsFrame.mainBetStandard:Hide()
-- Standard 1:1
payoutsFrame.standardPayout = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.standardPayout:SetPoint("TOPLEFT", payoutsFrame, 87, -93)
payoutsFrame.standardPayout:SetJustifyH("LEFT")
payoutsFrame.standardPayout:SetText("1:1")
payoutsFrame.standardPayout:SetTextColor(1, 0.973, 0.4)
payoutsFrame.standardPayout:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.standardPayout:Hide()
-- Blackjack
payoutsFrame.mainBetBlackjack = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.mainBetBlackjack:SetPoint("TOPLEFT", payoutsFrame, 137, -60)
payoutsFrame.mainBetBlackjack:SetJustifyH("LEFT")
payoutsFrame.mainBetBlackjack:SetText("Blackjack")
payoutsFrame.mainBetBlackjack:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
payoutsFrame.mainBetBlackjack:Hide()
-- Blackjack 3:2
payoutsFrame.blackjackPayout = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.blackjackPayout:SetPoint("TOPLEFT", payoutsFrame, 214, -93)
payoutsFrame.blackjackPayout:SetJustifyH("LEFT")
payoutsFrame.blackjackPayout:SetText("3:2")
payoutsFrame.blackjackPayout:SetTextColor(1, 0.973, 0.4)
payoutsFrame.blackjackPayout:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.blackjackPayout:Hide()
-- (PP) Mixed Pair
payoutsFrame.mixedPairPP = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.mixedPairPP:SetPoint("TOPLEFT", payoutsFrame, 15, -175)
payoutsFrame.mixedPairPP:SetJustifyH("LEFT")
payoutsFrame.mixedPairPP:SetText("Mixed Pair")
payoutsFrame.mixedPairPP:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
payoutsFrame.mixedPairPP:Hide()
-- (PP) Mixed Pair 5:1
payoutsFrame.mixedPairPayout = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.mixedPairPayout:SetPoint("TOPLEFT", payoutsFrame, 89, -208)
payoutsFrame.mixedPairPayout:SetJustifyH("LEFT")
payoutsFrame.mixedPairPayout:SetText(mixedPairPayoutValue .. ":1")
payoutsFrame.mixedPairPayout:SetTextColor(1, 0.973, 0.4)
payoutsFrame.mixedPairPayout:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.mixedPairPayout:Hide()
-- (PP) Coloured Pair
payoutsFrame.colouredPairPP = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.colouredPairPP:SetPoint("TOPLEFT", payoutsFrame, 138, -175)
payoutsFrame.colouredPairPP:SetJustifyH("LEFT")
payoutsFrame.colouredPairPP:SetText("Coloured Pair")
payoutsFrame.colouredPairPP:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
payoutsFrame.colouredPairPP:Hide()
-- (PP) Coloured Pair 10:1
payoutsFrame.colouredPairPayout = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.colouredPairPayout:SetPoint("TOPLEFT", payoutsFrame, 212, -208)
payoutsFrame.colouredPairPayout:SetJustifyH("LEFT")
payoutsFrame.colouredPairPayout:SetText(colouredPairPayoutValue .. ":1")
payoutsFrame.colouredPairPayout:SetTextColor(1, 0.973, 0.4)
payoutsFrame.colouredPairPayout:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.colouredPairPayout:Hide()
-- (PP) Perfect Pair
payoutsFrame.perfectPairPP = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.perfectPairPP:SetPoint("TOPLEFT", payoutsFrame, 15, -248)
payoutsFrame.perfectPairPP:SetJustifyH("LEFT")
payoutsFrame.perfectPairPP:SetText("Perfect Pair")
payoutsFrame.perfectPairPP:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
payoutsFrame.perfectPairPP:Hide()
-- (PP) Perfect Pair 25:1
payoutsFrame.perfectPairPayout = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.perfectPairPayout:SetPoint("TOPLEFT", payoutsFrame, 89, -280)
payoutsFrame.perfectPairPayout:SetJustifyH("LEFT")
payoutsFrame.perfectPairPayout:SetText(perfectPairPayoutValue .. ":1")
payoutsFrame.perfectPairPayout:SetTextColor(1, 0.973, 0.4)
payoutsFrame.perfectPairPayout:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.perfectPairPayout:Hide()
-- Flush
payoutsFrame.flush213 = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.flush213:SetPoint("TOPLEFT", payoutsFrame, 15, -345)
payoutsFrame.flush213:SetJustifyH("LEFT")
payoutsFrame.flush213:SetText("Flush")
payoutsFrame.flush213:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
payoutsFrame.flush213:Hide()
-- Flush 5:1
payoutsFrame.flushPayout = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.flushPayout:SetPoint("TOPLEFT", payoutsFrame, 126, -377)
payoutsFrame.flushPayout:SetJustifyH("LEFT")
payoutsFrame.flushPayout:SetText(flushPayoutValue .. ":1")
payoutsFrame.flushPayout:SetTextColor(1, 0.973, 0.4)
payoutsFrame.flushPayout:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.flushPayout:Hide()
-- Straight
payoutsFrame.straight213 = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.straight213:SetPoint("TOPLEFT", payoutsFrame, 15, -417)
payoutsFrame.straight213:SetJustifyH("LEFT")
payoutsFrame.straight213:SetText("Straight")
payoutsFrame.straight213:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
payoutsFrame.straight213:Hide()
-- Straight 10:1
payoutsFrame.straightPayout = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.straightPayout:SetPoint("TOPLEFT", payoutsFrame, 125, -450)
payoutsFrame.straightPayout:SetJustifyH("LEFT")
payoutsFrame.straightPayout:SetText(straightPayoutValue .. ":1")
payoutsFrame.straightPayout:SetTextColor(1, 0.973, 0.4)
payoutsFrame.straightPayout:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.straightPayout:Hide()
-- Three of a Kind
payoutsFrame.threeOfAKind213 = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.threeOfAKind213:SetPoint("TOPLEFT", payoutsFrame, 15, -491)
payoutsFrame.threeOfAKind213:SetJustifyH("LEFT")
payoutsFrame.threeOfAKind213:SetText("Three of a Kind")
payoutsFrame.threeOfAKind213:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
payoutsFrame.threeOfAKind213:Hide()
-- Three of a Kind 25:1
payoutsFrame.threeOfAKindPayout = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.threeOfAKindPayout:SetPoint("TOPLEFT", payoutsFrame, 127, -525)
payoutsFrame.threeOfAKindPayout:SetJustifyH("LEFT")
payoutsFrame.threeOfAKindPayout:SetText(threeOfAKindPayoutValue .. ":1")
payoutsFrame.threeOfAKindPayout:SetTextColor(1, 0.973, 0.4)
payoutsFrame.threeOfAKindPayout:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.threeOfAKindPayout:Hide()
-- Straight Flush
payoutsFrame.straightFlush213 = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.straightFlush213:SetPoint("TOPLEFT", payoutsFrame, 15, -563)
payoutsFrame.straightFlush213:SetJustifyH("LEFT")
payoutsFrame.straightFlush213:SetText("Straight Flush")
payoutsFrame.straightFlush213:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
payoutsFrame.straightFlush213:Hide()
-- Straight Flush 40:1
payoutsFrame.straightFlushPayout = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.straightFlushPayout:SetPoint("TOPLEFT", payoutsFrame, 127, -595)
payoutsFrame.straightFlushPayout:SetJustifyH("LEFT")
payoutsFrame.straightFlushPayout:SetText(straightFlushPayoutValue .. ":1")
payoutsFrame.straightFlushPayout:SetTextColor(1, 0.973, 0.4)
payoutsFrame.straightFlushPayout:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.straightFlushPayout:Hide()
-- Suited Three of a Kind
payoutsFrame.suitedThreeOfAKind213 = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.suitedThreeOfAKind213:SetPoint("TOPLEFT", payoutsFrame, 15, -637)
payoutsFrame.suitedThreeOfAKind213:SetJustifyH("LEFT")
payoutsFrame.suitedThreeOfAKind213:SetText("Suited Three of a Kind")
payoutsFrame.suitedThreeOfAKind213:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
payoutsFrame.suitedThreeOfAKind213:Hide()
-- Suited Three of a Kind 100:1
payoutsFrame.suitedThreeOfAKindPayout = payoutsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
payoutsFrame.suitedThreeOfAKindPayout:SetPoint("TOPLEFT", payoutsFrame, 126, -669)
payoutsFrame.suitedThreeOfAKindPayout:SetJustifyH("LEFT")
payoutsFrame.suitedThreeOfAKindPayout:SetText(suitedThreeOfAKindPayoutValue .. ":1")
payoutsFrame.suitedThreeOfAKindPayout:SetTextColor(1, 0.973, 0.4)
payoutsFrame.suitedThreeOfAKindPayout:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
payoutsFrame.suitedThreeOfAKindPayout:Hide()

-- Creating card textures
-- Standard 1
payoutsFrame.card1image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card1image:SetSize(32, 64)
payoutsFrame.card1image:SetPoint("TOPLEFT", payoutsFrame, 17, -70)
payoutsFrame.card1image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\JH.tga")
payoutsFrame.card1image:SetBlendMode("BLEND")
payoutsFrame.card1image:SetDrawLayer("ARTWORK")
payoutsFrame.card1image:Hide()
-- Standard 2
payoutsFrame.card2image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card2image:SetSize(32, 64)
payoutsFrame.card2image:SetPoint("TOPLEFT", payoutsFrame, 52, -70)
payoutsFrame.card2image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\8S.tga")
payoutsFrame.card2image:SetBlendMode("BLEND")
payoutsFrame.card2image:SetDrawLayer("ARTWORK")
payoutsFrame.card2image:Hide()
-- Blackjack 1
payoutsFrame.card3image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card3image:SetSize(32, 64)
payoutsFrame.card3image:SetPoint("TOPLEFT", payoutsFrame, 140, -70)
payoutsFrame.card3image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\AS.tga")
payoutsFrame.card3image:SetBlendMode("BLEND")
payoutsFrame.card3image:SetDrawLayer("ARTWORK")
payoutsFrame.card3image:Hide()
-- Blackjack 2
payoutsFrame.card4image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card4image:SetSize(32, 64)
payoutsFrame.card4image:SetPoint("TOPLEFT", payoutsFrame, 176, -70)
payoutsFrame.card4image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\QD.tga")
payoutsFrame.card4image:SetBlendMode("BLEND")
payoutsFrame.card4image:SetDrawLayer("ARTWORK")
payoutsFrame.card4image:Hide()
-- (PP) Mixed Pair 1
payoutsFrame.card5image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card5image:SetSize(32, 64)
payoutsFrame.card5image:SetPoint("TOPLEFT", payoutsFrame, 17, -185)
payoutsFrame.card5image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\2C.tga")
payoutsFrame.card5image:SetBlendMode("BLEND")
payoutsFrame.card5image:SetDrawLayer("ARTWORK")
payoutsFrame.card5image:Hide()
-- (PP) Mixed Pair 2
payoutsFrame.card6image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card6image:SetSize(32, 64)
payoutsFrame.card6image:SetPoint("TOPLEFT", payoutsFrame, 52, -185)
payoutsFrame.card6image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\2D.tga")
payoutsFrame.card6image:SetBlendMode("BLEND")
payoutsFrame.card6image:SetDrawLayer("ARTWORK")
payoutsFrame.card6image:Hide()
-- (PP) Coloured Pair 1
payoutsFrame.card7image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card7image:SetSize(32, 64)
payoutsFrame.card7image:SetPoint("TOPLEFT", payoutsFrame, 140, -185)
payoutsFrame.card7image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\6S.tga")
payoutsFrame.card7image:SetBlendMode("BLEND")
payoutsFrame.card7image:SetDrawLayer("ARTWORK")
payoutsFrame.card7image:Hide()
-- (PP) Coloured Pair 2
payoutsFrame.card8image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card8image:SetSize(32, 64)
payoutsFrame.card8image:SetPoint("TOPLEFT", payoutsFrame, 176, -185)
payoutsFrame.card8image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\6C.tga")
payoutsFrame.card8image:SetBlendMode("BLEND")
payoutsFrame.card8image:SetDrawLayer("ARTWORK")
payoutsFrame.card8image:Hide()
-- (PP) Perfect Pair 1
payoutsFrame.card9image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card9image:SetSize(32, 64)
payoutsFrame.card9image:SetPoint("TOPLEFT", payoutsFrame, 17, -257)
payoutsFrame.card9image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\5D.tga")
payoutsFrame.card9image:SetBlendMode("BLEND")
payoutsFrame.card9image:SetDrawLayer("ARTWORK")
payoutsFrame.card9image:Hide()
-- (PP) Perfect Pair 2
payoutsFrame.card10image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card10image:SetSize(32, 64)
payoutsFrame.card10image:SetPoint("TOPLEFT", payoutsFrame, 52, -257)
payoutsFrame.card10image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\5D.tga")
payoutsFrame.card10image:SetBlendMode("BLEND")
payoutsFrame.card10image:SetDrawLayer("ARTWORK")
payoutsFrame.card10image:Hide()
-- (21+3) Flush 1
payoutsFrame.card11image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card11image:SetSize(32, 64)
payoutsFrame.card11image:SetPoint("TOPLEFT", payoutsFrame, 17, -354)
payoutsFrame.card11image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\3S.tga")
payoutsFrame.card11image:SetBlendMode("BLEND")
payoutsFrame.card11image:SetDrawLayer("ARTWORK")
payoutsFrame.card11image:Hide()
-- (21+3) Flush 2
payoutsFrame.card12image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card12image:SetSize(32, 64)
payoutsFrame.card12image:SetPoint("TOPLEFT", payoutsFrame, 52, -354)
payoutsFrame.card12image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\7S.tga")
payoutsFrame.card12image:SetBlendMode("BLEND")
payoutsFrame.card12image:SetDrawLayer("ARTWORK")
payoutsFrame.card12image:Hide()
-- (21+3) Flush 3
payoutsFrame.card13image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card13image:SetSize(32, 64)
payoutsFrame.card13image:SetPoint("TOPLEFT", payoutsFrame, 88, -354)
payoutsFrame.card13image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\QS.tga")
payoutsFrame.card13image:SetBlendMode("BLEND")
payoutsFrame.card13image:SetDrawLayer("ARTWORK")
payoutsFrame.card13image:Hide()
-- (21+3) Straight 1
payoutsFrame.card14image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card14image:SetSize(32, 64)
payoutsFrame.card14image:SetPoint("TOPLEFT", payoutsFrame, 17, -426)
payoutsFrame.card14image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\2H.tga")
payoutsFrame.card14image:SetBlendMode("BLEND")
payoutsFrame.card14image:SetDrawLayer("ARTWORK")
payoutsFrame.card14image:Hide()
-- (21+3) Straight 2
payoutsFrame.card15image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card15image:SetSize(32, 64)
payoutsFrame.card15image:SetPoint("TOPLEFT", payoutsFrame, 52, -426)
payoutsFrame.card15image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\3C.tga")
payoutsFrame.card15image:SetBlendMode("BLEND")
payoutsFrame.card15image:SetDrawLayer("ARTWORK")
payoutsFrame.card15image:Hide()
-- (21+3) Straight 3
payoutsFrame.card16image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card16image:SetSize(32, 64)
payoutsFrame.card16image:SetPoint("TOPLEFT", payoutsFrame, 88, -426)
payoutsFrame.card16image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\4D.tga")
payoutsFrame.card16image:SetBlendMode("BLEND")
payoutsFrame.card16image:SetDrawLayer("ARTWORK")
payoutsFrame.card16image:Hide()
-- (21+3) Three of a Kind 1
payoutsFrame.card17image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card17image:SetSize(32, 64)
payoutsFrame.card17image:SetPoint("TOPLEFT", payoutsFrame, 17, -500)
payoutsFrame.card17image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\AC.tga")
payoutsFrame.card17image:SetBlendMode("BLEND")
payoutsFrame.card17image:SetDrawLayer("ARTWORK")
payoutsFrame.card17image:Hide()
-- (21+3) Three of a Kind 2
payoutsFrame.card18image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card18image:SetSize(32, 64)
payoutsFrame.card18image:SetPoint("TOPLEFT", payoutsFrame, 52, -500)
payoutsFrame.card18image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\AD.tga")
payoutsFrame.card18image:SetBlendMode("BLEND")
payoutsFrame.card18image:SetDrawLayer("ARTWORK")
payoutsFrame.card18image:Hide()
-- (21+3) Three of a Kind 3
payoutsFrame.card19image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card19image:SetSize(32, 64)
payoutsFrame.card19image:SetPoint("TOPLEFT", payoutsFrame, 88, -500)
payoutsFrame.card19image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\AH.tga")
payoutsFrame.card19image:SetBlendMode("BLEND")
payoutsFrame.card19image:SetDrawLayer("ARTWORK")
payoutsFrame.card19image:Hide()
-- (21+3) Straight Flush 1
payoutsFrame.card20image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card20image:SetSize(32, 64)
payoutsFrame.card20image:SetPoint("TOPLEFT", payoutsFrame, 17, -572)
payoutsFrame.card20image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\2D.tga")
payoutsFrame.card20image:SetBlendMode("BLEND")
payoutsFrame.card20image:SetDrawLayer("ARTWORK")
payoutsFrame.card20image:Hide()
-- (21+3) Straight Flush 2
payoutsFrame.card21image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card21image:SetSize(32, 64)
payoutsFrame.card21image:SetPoint("TOPLEFT", payoutsFrame, 52, -572)
payoutsFrame.card21image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\3D.tga")
payoutsFrame.card21image:SetBlendMode("BLEND")
payoutsFrame.card21image:SetDrawLayer("ARTWORK")
payoutsFrame.card21image:Hide()
-- (21+3) Straight Flush 3
payoutsFrame.card22image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card22image:SetSize(32, 64)
payoutsFrame.card22image:SetPoint("TOPLEFT", payoutsFrame, 88, -572)
payoutsFrame.card22image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\4D.tga")
payoutsFrame.card22image:SetBlendMode("BLEND")
payoutsFrame.card22image:SetDrawLayer("ARTWORK")
payoutsFrame.card22image:Hide()
-- (21+3) Suited Three of a Kind 1
payoutsFrame.card23image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card23image:SetSize(32, 64)
payoutsFrame.card23image:SetPoint("TOPLEFT", payoutsFrame, 17, -646)
payoutsFrame.card23image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\AS.tga")
payoutsFrame.card23image:SetBlendMode("BLEND")
payoutsFrame.card23image:SetDrawLayer("ARTWORK")
payoutsFrame.card23image:Hide()
-- (21+3) Suited Three of a Kind 2
payoutsFrame.card24image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card24image:SetSize(32, 64)
payoutsFrame.card24image:SetPoint("TOPLEFT", payoutsFrame, 52, -646)
payoutsFrame.card24image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\AS.tga")
payoutsFrame.card24image:SetBlendMode("BLEND")
payoutsFrame.card24image:SetDrawLayer("ARTWORK")
payoutsFrame.card24image:Hide()
-- (21+3) Suited Three of a Kind 3
payoutsFrame.card25image = payoutsFrame:CreateTexture(nil, "OVERLAY")
payoutsFrame.card25image:SetSize(32, 64)
payoutsFrame.card25image:SetPoint("TOPLEFT", payoutsFrame, 88, -646)
payoutsFrame.card25image:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\AS.tga")
payoutsFrame.card25image:SetBlendMode("BLEND")
payoutsFrame.card25image:SetDrawLayer("ARTWORK")
payoutsFrame.card25image:Hide()
























-- >> DEALT CARDS WINDOW <<
-- >> DEALT CARDS WINDOW <<
-- >> DEALT CARDS WINDOW <<

-- >> PLAYER 1 <<
-- >> PLAYER 1 <<
-- >> PLAYER 1 <<

-- Player Dealt Cards Frame
player1dealtCardsFrame= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player1dealtCardsFrame:SetSize(656, 200)
player1dealtCardsFrame:SetPoint("BOTTOM", playerFrame, 0, 5)
player1dealtCardsFrame:SetFrameStrata("HIGH")
player1dealtCardsFrame:SetFrameLevel(6)
player1dealtCardsFrame:Hide()

-- "Player" button which displays Player's Main Hand cards
player1dealtCardsFrame.playerCardsButton = CreateFrame("Button", nil, player1dealtCardsFrame, "GameMenuButtonTemplate")
player1dealtCardsFrame.playerCardsButton:SetPoint("TOPLEFT", player1dealtCardsFrame, 8, -8)
player1dealtCardsFrame.playerCardsButton:SetSize(75, 25)
player1dealtCardsFrame.playerCardsButton:SetText("Player")
player1dealtCardsFrame.playerCardsButton:Disable()
player1dealtCardsFrame.playerCardsButton:Hide()

player1dealtCardsFrame.notStartedYetText = player1dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrame.notStartedYetText:SetPoint("CENTER", player1dealtCardsFrame, 0, 0)
player1dealtCardsFrame.notStartedYetText:SetJustifyH("CENTER")
player1dealtCardsFrame.notStartedYetText:SetText("The round hasn't started yet")
player1dealtCardsFrame.notStartedYetText:SetFont("Fonts\\FRIZQT__.TTF", 20, "OUTLINE")
player1dealtCardsFrame.notStartedYetText:Hide()

player1dealtCardsFrame.player1MainCardImage1 = player1dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrame.player1MainCardImage1:SetSize(85, 170)
player1dealtCardsFrame.player1MainCardImage1:SetPoint("LEFT", player1dealtCardsFrame, 10, -7)
player1dealtCardsFrame.player1MainCardImage1:SetBlendMode("BLEND")
player1dealtCardsFrame.player1MainCardImage1:SetDrawLayer("ARTWORK")

player1dealtCardsFrame.player1MainCardImage2 = player1dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrame.player1MainCardImage2:SetSize(85, 170)
player1dealtCardsFrame.player1MainCardImage2:SetPoint("LEFT", player1dealtCardsFrame, 102, -7)
player1dealtCardsFrame.player1MainCardImage2:SetBlendMode("BLEND")
player1dealtCardsFrame.player1MainCardImage2:SetDrawLayer("ARTWORK")

player1dealtCardsFrame.player1MainCardImage3 = player1dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrame.player1MainCardImage3:SetSize(85, 170)
player1dealtCardsFrame.player1MainCardImage3:SetPoint("LEFT", player1dealtCardsFrame, 194, -7)
player1dealtCardsFrame.player1MainCardImage3:SetBlendMode("BLEND")
player1dealtCardsFrame.player1MainCardImage3:SetDrawLayer("ARTWORK")

player1dealtCardsFrame.player1MainCardImage4 = player1dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrame.player1MainCardImage4:SetSize(85, 170)
player1dealtCardsFrame.player1MainCardImage4:SetPoint("LEFT", player1dealtCardsFrame, 286, -7)
player1dealtCardsFrame.player1MainCardImage4:SetBlendMode("BLEND")
player1dealtCardsFrame.player1MainCardImage4:SetDrawLayer("ARTWORK")

player1dealtCardsFrame.player1MainCardImage5 = player1dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrame.player1MainCardImage5:SetSize(85, 170)
player1dealtCardsFrame.player1MainCardImage5:SetPoint("LEFT", player1dealtCardsFrame, 378, -7)
player1dealtCardsFrame.player1MainCardImage5:SetBlendMode("BLEND")
player1dealtCardsFrame.player1MainCardImage5:SetDrawLayer("ARTWORK")

player1dealtCardsFrame.player1MainCardImage6 = player1dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrame.player1MainCardImage6:SetSize(85, 170)
player1dealtCardsFrame.player1MainCardImage6:SetPoint("LEFT", player1dealtCardsFrame, 470, -7)
player1dealtCardsFrame.player1MainCardImage6:SetBlendMode("BLEND")
player1dealtCardsFrame.player1MainCardImage6:SetDrawLayer("ARTWORK")

player1dealtCardsFrame.player1MainCardImage7 = player1dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrame.player1MainCardImage7:SetSize(85, 170)
player1dealtCardsFrame.player1MainCardImage7:SetPoint("LEFT", player1dealtCardsFrame, 562, -7)
player1dealtCardsFrame.player1MainCardImage7:SetBlendMode("BLEND")
player1dealtCardsFrame.player1MainCardImage7:SetDrawLayer("ARTWORK")

player1dealtCardsFrame.playerFirstCardText = player1dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrame.playerFirstCardText:SetPoint("LEFT", player1dealtCardsFrame, 23, -80)
player1dealtCardsFrame.playerFirstCardText:SetJustifyH("CENTER")
player1dealtCardsFrame.playerFirstCardText:SetText("1st Card")
player1dealtCardsFrame.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrame.playerFirstCardText:Hide()

player1dealtCardsFrame.playerSecondCardText = player1dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrame.playerSecondCardText:SetPoint("LEFT", player1dealtCardsFrame, 112, -80)
player1dealtCardsFrame.playerSecondCardText:SetJustifyH("CENTER")
player1dealtCardsFrame.playerSecondCardText:SetText("2nd Card")
player1dealtCardsFrame.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrame.playerSecondCardText:Hide()

player1dealtCardsFrame.playerThirdCardText = player1dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrame.playerThirdCardText:SetPoint("LEFT", player1dealtCardsFrame, 207, -80)
player1dealtCardsFrame.playerThirdCardText:SetJustifyH("CENTER")
player1dealtCardsFrame.playerThirdCardText:SetText("3rd Card")
player1dealtCardsFrame.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrame.playerThirdCardText:Hide()

player1dealtCardsFrame.playerFourthCardText = player1dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrame.playerFourthCardText:SetPoint("LEFT", player1dealtCardsFrame, 299, -80)
player1dealtCardsFrame.playerFourthCardText:SetJustifyH("CENTER")
player1dealtCardsFrame.playerFourthCardText:SetText("4th Card")
player1dealtCardsFrame.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrame.playerFourthCardText:Hide()

player1dealtCardsFrame.playerFifthCardText = player1dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrame.playerFifthCardText:SetPoint("LEFT", player1dealtCardsFrame, 392, -80)
player1dealtCardsFrame.playerFifthCardText:SetJustifyH("CENTER")
player1dealtCardsFrame.playerFifthCardText:SetText("5th Card")
player1dealtCardsFrame.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrame.playerFifthCardText:Hide()

player1dealtCardsFrame.playerSixthCardText = player1dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrame.playerSixthCardText:SetPoint("LEFT", player1dealtCardsFrame, 483, -80)
player1dealtCardsFrame.playerSixthCardText:SetJustifyH("CENTER")
player1dealtCardsFrame.playerSixthCardText:SetText("6th Card")
player1dealtCardsFrame.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrame.playerSixthCardText:Hide()

player1dealtCardsFrame.playerSeventhCardText = player1dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrame.playerSeventhCardText:SetPoint("LEFT", player1dealtCardsFrame, 576, -80)
player1dealtCardsFrame.playerSeventhCardText:SetJustifyH("CENTER")
player1dealtCardsFrame.playerSeventhCardText:SetText("7th Card")
player1dealtCardsFrame.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrame.playerSeventhCardText:Hide()

-- Player H1 Dealt Cards Frame
player1dealtCardsFrameSplitH1= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player1dealtCardsFrameSplitH1:SetSize(656, 200)
player1dealtCardsFrameSplitH1:SetPoint("BOTTOM", playerFrame, 0, 5)
player1dealtCardsFrameSplitH1:SetFrameStrata("HIGH")
player1dealtCardsFrameSplitH1:SetFrameLevel(5)
player1dealtCardsFrameSplitH1:Hide()

-- "Hand 1" button which displays Player's Hand 1 cards
player1dealtCardsFrameSplitH1.playerH1CardsButton = CreateFrame("Button", nil, player1dealtCardsFrameSplitH1, "GameMenuButtonTemplate")
player1dealtCardsFrameSplitH1.playerH1CardsButton:SetPoint("TOPLEFT", player1dealtCardsFrameSplitH1, 8, -8)
player1dealtCardsFrameSplitH1.playerH1CardsButton:SetSize(75, 25)
player1dealtCardsFrameSplitH1.playerH1CardsButton:SetText("Hand 1")
player1dealtCardsFrameSplitH1.playerH1CardsButton:Disable()
player1dealtCardsFrameSplitH1.playerH1CardsButton:Hide()

-- "Hand 2" button which displays Player's Hand 2 cards
player1dealtCardsFrameSplitH1.playerH2CardsButton = CreateFrame("Button", nil, player1dealtCardsFrameSplitH1, "GameMenuButtonTemplate")
player1dealtCardsFrameSplitH1.playerH2CardsButton:SetPoint("TOPLEFT", player1dealtCardsFrameSplitH1, 84, -8)
player1dealtCardsFrameSplitH1.playerH2CardsButton:SetSize(75, 25)
player1dealtCardsFrameSplitH1.playerH2CardsButton:SetText("Hand 2")
player1dealtCardsFrameSplitH1.playerH2CardsButton:Hide()

player1dealtCardsFrameSplitH1.player1H1CardImage1 = player1dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH1.player1H1CardImage1:SetSize(85, 170)
player1dealtCardsFrameSplitH1.player1H1CardImage1:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 10, -7)
player1dealtCardsFrameSplitH1.player1H1CardImage1:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH1.player1H1CardImage1:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH1.player1H1CardImage2 = player1dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH1.player1H1CardImage2:SetSize(85, 170)
player1dealtCardsFrameSplitH1.player1H1CardImage2:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 102, -7)
player1dealtCardsFrameSplitH1.player1H1CardImage2:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH1.player1H1CardImage2:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH1.player1H1CardImage3 = player1dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH1.player1H1CardImage3:SetSize(85, 170)
player1dealtCardsFrameSplitH1.player1H1CardImage3:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 194, -7)
player1dealtCardsFrameSplitH1.player1H1CardImage3:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH1.player1H1CardImage3:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH1.player1H1CardImage4 = player1dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH1.player1H1CardImage4:SetSize(85, 170)
player1dealtCardsFrameSplitH1.player1H1CardImage4:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 286, -7)
player1dealtCardsFrameSplitH1.player1H1CardImage4:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH1.player1H1CardImage4:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH1.player1H1CardImage5 = player1dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH1.player1H1CardImage5:SetSize(85, 170)
player1dealtCardsFrameSplitH1.player1H1CardImage5:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 378, -7)
player1dealtCardsFrameSplitH1.player1H1CardImage5:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH1.player1H1CardImage5:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH1.player1H1CardImage6 = player1dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH1.player1H1CardImage6:SetSize(85, 170)
player1dealtCardsFrameSplitH1.player1H1CardImage6:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 470, -7)
player1dealtCardsFrameSplitH1.player1H1CardImage6:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH1.player1H1CardImage6:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH1.player1H1CardImage7 = player1dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH1.player1H1CardImage7:SetSize(85, 170)
player1dealtCardsFrameSplitH1.player1H1CardImage7:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 562, -7)
player1dealtCardsFrameSplitH1.player1H1CardImage7:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH1.player1H1CardImage7:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH1.playerFirstCardText = player1dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH1.playerFirstCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 23, -80)
player1dealtCardsFrameSplitH1.playerFirstCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH1.playerFirstCardText:SetText("1st Card")
player1dealtCardsFrameSplitH1.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH1.playerFirstCardText:Hide()

player1dealtCardsFrameSplitH1.playerSecondCardText = player1dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH1.playerSecondCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 112, -80)
player1dealtCardsFrameSplitH1.playerSecondCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH1.playerSecondCardText:SetText("2nd Card")
player1dealtCardsFrameSplitH1.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH1.playerSecondCardText:Hide()

player1dealtCardsFrameSplitH1.playerThirdCardText = player1dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH1.playerThirdCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 207, -80)
player1dealtCardsFrameSplitH1.playerThirdCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH1.playerThirdCardText:SetText("3rd Card")
player1dealtCardsFrameSplitH1.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH1.playerThirdCardText:Hide()

player1dealtCardsFrameSplitH1.playerFourthCardText = player1dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH1.playerFourthCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 299, -80)
player1dealtCardsFrameSplitH1.playerFourthCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH1.playerFourthCardText:SetText("4th Card")
player1dealtCardsFrameSplitH1.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH1.playerFourthCardText:Hide()

player1dealtCardsFrameSplitH1.playerFifthCardText = player1dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH1.playerFifthCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 392, -80)
player1dealtCardsFrameSplitH1.playerFifthCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH1.playerFifthCardText:SetText("5th Card")
player1dealtCardsFrameSplitH1.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH1.playerFifthCardText:Hide()

player1dealtCardsFrameSplitH1.playerSixthCardText = player1dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH1.playerSixthCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 483, -80)
player1dealtCardsFrameSplitH1.playerSixthCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH1.playerSixthCardText:SetText("6th Card")
player1dealtCardsFrameSplitH1.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH1.playerSixthCardText:Hide()

player1dealtCardsFrameSplitH1.playerSeventhCardText = player1dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH1.playerSeventhCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH1, 576, -80)
player1dealtCardsFrameSplitH1.playerSeventhCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH1.playerSeventhCardText:SetText("7th Card")
player1dealtCardsFrameSplitH1.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH1.playerSeventhCardText:Hide()

-- Player H2 Dealt Cards Frame
player1dealtCardsFrameSplitH2= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player1dealtCardsFrameSplitH2:SetSize(656, 200)
player1dealtCardsFrameSplitH2:SetPoint("BOTTOM", playerFrame, 0, 5)
player1dealtCardsFrameSplitH2:SetFrameStrata("HIGH")
player1dealtCardsFrameSplitH2:SetFrameLevel(5)
player1dealtCardsFrameSplitH2:Hide()

-- "Hand 1" button which displays Player's Hand 1 cards
player1dealtCardsFrameSplitH2.playerH1CardsButton = CreateFrame("Button", nil, player1dealtCardsFrameSplitH2, "GameMenuButtonTemplate")
player1dealtCardsFrameSplitH2.playerH1CardsButton:SetPoint("TOPLEFT", player1dealtCardsFrameSplitH2, 8, -8)
player1dealtCardsFrameSplitH2.playerH1CardsButton:SetSize(75, 25)
player1dealtCardsFrameSplitH2.playerH1CardsButton:SetText("Hand 1")
player1dealtCardsFrameSplitH2.playerH1CardsButton:Hide()

-- "Hand 2" button which displays Player's Hand 2 cards
player1dealtCardsFrameSplitH2.playerH2CardsButton = CreateFrame("Button", nil, player1dealtCardsFrameSplitH2, "GameMenuButtonTemplate")
player1dealtCardsFrameSplitH2.playerH2CardsButton:SetPoint("TOPLEFT", player1dealtCardsFrameSplitH2, 84, -8)
player1dealtCardsFrameSplitH2.playerH2CardsButton:SetSize(75, 25)
player1dealtCardsFrameSplitH2.playerH2CardsButton:SetText("Hand 2")
player1dealtCardsFrameSplitH2.playerH2CardsButton:Disable()
player1dealtCardsFrameSplitH2.playerH2CardsButton:Hide()

player1dealtCardsFrameSplitH2.player1H2CardImage1 = player1dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH2.player1H2CardImage1:SetSize(85, 170)
player1dealtCardsFrameSplitH2.player1H2CardImage1:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 10, -7)
player1dealtCardsFrameSplitH2.player1H2CardImage1:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH2.player1H2CardImage1:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH2.player1H2CardImage2 = player1dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH2.player1H2CardImage2:SetSize(85, 170)
player1dealtCardsFrameSplitH2.player1H2CardImage2:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 102, -7)
player1dealtCardsFrameSplitH2.player1H2CardImage2:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH2.player1H2CardImage2:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH2.player1H2CardImage3 = player1dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH2.player1H2CardImage3:SetSize(85, 170)
player1dealtCardsFrameSplitH2.player1H2CardImage3:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 194, -7)
player1dealtCardsFrameSplitH2.player1H2CardImage3:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH2.player1H2CardImage3:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH2.player1H2CardImage4 = player1dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH2.player1H2CardImage4:SetSize(85, 170)
player1dealtCardsFrameSplitH2.player1H2CardImage4:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 286, -7)
player1dealtCardsFrameSplitH2.player1H2CardImage4:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH2.player1H2CardImage4:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH2.player1H2CardImage5 = player1dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH2.player1H2CardImage5:SetSize(85, 170)
player1dealtCardsFrameSplitH2.player1H2CardImage5:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 378, -7)
player1dealtCardsFrameSplitH2.player1H2CardImage5:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH2.player1H2CardImage5:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH2.player1H2CardImage6 = player1dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH2.player1H2CardImage6:SetSize(85, 170)
player1dealtCardsFrameSplitH2.player1H2CardImage6:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 470, -7)
player1dealtCardsFrameSplitH2.player1H2CardImage6:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH2.player1H2CardImage6:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH2.player1H2CardImage7 = player1dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player1dealtCardsFrameSplitH2.player1H2CardImage7:SetSize(85, 170)
player1dealtCardsFrameSplitH2.player1H2CardImage7:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 562, -7)
player1dealtCardsFrameSplitH2.player1H2CardImage7:SetBlendMode("BLEND")
player1dealtCardsFrameSplitH2.player1H2CardImage7:SetDrawLayer("ARTWORK")

player1dealtCardsFrameSplitH2.playerFirstCardText = player1dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH2.playerFirstCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 23, -80)
player1dealtCardsFrameSplitH2.playerFirstCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH2.playerFirstCardText:SetText("1st Card")
player1dealtCardsFrameSplitH2.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH2.playerFirstCardText:Hide()

player1dealtCardsFrameSplitH2.playerSecondCardText = player1dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH2.playerSecondCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 112, -80)
player1dealtCardsFrameSplitH2.playerSecondCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH2.playerSecondCardText:SetText("2nd Card")
player1dealtCardsFrameSplitH2.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH2.playerSecondCardText:Hide()

player1dealtCardsFrameSplitH2.playerThirdCardText = player1dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH2.playerThirdCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 207, -80)
player1dealtCardsFrameSplitH2.playerThirdCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH2.playerThirdCardText:SetText("3rd Card")
player1dealtCardsFrameSplitH2.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH2.playerThirdCardText:Hide()

player1dealtCardsFrameSplitH2.playerFourthCardText = player1dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH2.playerFourthCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 299, -80)
player1dealtCardsFrameSplitH2.playerFourthCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH2.playerFourthCardText:SetText("4th Card")
player1dealtCardsFrameSplitH2.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH2.playerFourthCardText:Hide()

player1dealtCardsFrameSplitH2.playerFifthCardText = player1dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH2.playerFifthCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 392, -80)
player1dealtCardsFrameSplitH2.playerFifthCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH2.playerFifthCardText:SetText("5th Card")
player1dealtCardsFrameSplitH2.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH2.playerFifthCardText:Hide()

player1dealtCardsFrameSplitH2.playerSixthCardText = player1dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH2.playerSixthCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 483, -80)
player1dealtCardsFrameSplitH2.playerSixthCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH2.playerSixthCardText:SetText("6th Card")
player1dealtCardsFrameSplitH2.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH2.playerSixthCardText:Hide()

player1dealtCardsFrameSplitH2.playerSeventhCardText = player1dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1dealtCardsFrameSplitH2.playerSeventhCardText:SetPoint("LEFT", player1dealtCardsFrameSplitH2, 576, -80)
player1dealtCardsFrameSplitH2.playerSeventhCardText:SetJustifyH("CENTER")
player1dealtCardsFrameSplitH2.playerSeventhCardText:SetText("7th Card")
player1dealtCardsFrameSplitH2.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1dealtCardsFrameSplitH2.playerSeventhCardText:Hide()







-- >> PLAYER 2 <<
-- >> PLAYER 2 <<
-- >> PLAYER 2 <<

-- Player Dealt Cards Frame
player2dealtCardsFrame= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player2dealtCardsFrame:SetSize(656, 200)
player2dealtCardsFrame:SetPoint("BOTTOM", playerFrame, 0, 5)
player2dealtCardsFrame:SetFrameStrata("HIGH")
player2dealtCardsFrame:SetFrameLevel(6)
player2dealtCardsFrame:Hide()

-- "Player" button which displays Player's Main Hand cards
player2dealtCardsFrame.playerCardsButton = CreateFrame("Button", nil, player2dealtCardsFrame, "GameMenuButtonTemplate")
player2dealtCardsFrame.playerCardsButton:SetPoint("TOPLEFT", player2dealtCardsFrame, 8, -8)
player2dealtCardsFrame.playerCardsButton:SetSize(75, 25)
player2dealtCardsFrame.playerCardsButton:SetText("Player")
player2dealtCardsFrame.playerCardsButton:Disable()
player2dealtCardsFrame.playerCardsButton:Hide()

player2dealtCardsFrame.notStartedYetText = player2dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrame.notStartedYetText:SetPoint("CENTER", player2dealtCardsFrame, 0, 0)
player2dealtCardsFrame.notStartedYetText:SetJustifyH("CENTER")
player2dealtCardsFrame.notStartedYetText:SetText("The round hasn't started yet")
player2dealtCardsFrame.notStartedYetText:SetFont("Fonts\\FRIZQT__.TTF", 20, "OUTLINE")
player2dealtCardsFrame.notStartedYetText:Hide()

player2dealtCardsFrame.player2MainCardImage1 = player2dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrame.player2MainCardImage1:SetSize(85, 170)
player2dealtCardsFrame.player2MainCardImage1:SetPoint("LEFT", player2dealtCardsFrame, 10, -7)
player2dealtCardsFrame.player2MainCardImage1:SetBlendMode("BLEND")
player2dealtCardsFrame.player2MainCardImage1:SetDrawLayer("ARTWORK")

player2dealtCardsFrame.player2MainCardImage2 = player2dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrame.player2MainCardImage2:SetSize(85, 170)
player2dealtCardsFrame.player2MainCardImage2:SetPoint("LEFT", player2dealtCardsFrame, 102, -7)
player2dealtCardsFrame.player2MainCardImage2:SetBlendMode("BLEND")
player2dealtCardsFrame.player2MainCardImage2:SetDrawLayer("ARTWORK")

player2dealtCardsFrame.player2MainCardImage3 = player2dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrame.player2MainCardImage3:SetSize(85, 170)
player2dealtCardsFrame.player2MainCardImage3:SetPoint("LEFT", player2dealtCardsFrame, 194, -7)
player2dealtCardsFrame.player2MainCardImage3:SetBlendMode("BLEND")
player2dealtCardsFrame.player2MainCardImage3:SetDrawLayer("ARTWORK")

player2dealtCardsFrame.player2MainCardImage4 = player2dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrame.player2MainCardImage4:SetSize(85, 170)
player2dealtCardsFrame.player2MainCardImage4:SetPoint("LEFT", player2dealtCardsFrame, 286, -7)
player2dealtCardsFrame.player2MainCardImage4:SetBlendMode("BLEND")
player2dealtCardsFrame.player2MainCardImage4:SetDrawLayer("ARTWORK")

player2dealtCardsFrame.player2MainCardImage5 = player2dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrame.player2MainCardImage5:SetSize(85, 170)
player2dealtCardsFrame.player2MainCardImage5:SetPoint("LEFT", player2dealtCardsFrame, 378, -7)
player2dealtCardsFrame.player2MainCardImage5:SetBlendMode("BLEND")
player2dealtCardsFrame.player2MainCardImage5:SetDrawLayer("ARTWORK")

player2dealtCardsFrame.player2MainCardImage6 = player2dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrame.player2MainCardImage6:SetSize(85, 170)
player2dealtCardsFrame.player2MainCardImage6:SetPoint("LEFT", player2dealtCardsFrame, 470, -7)
player2dealtCardsFrame.player2MainCardImage6:SetBlendMode("BLEND")
player2dealtCardsFrame.player2MainCardImage6:SetDrawLayer("ARTWORK")

player2dealtCardsFrame.player2MainCardImage7 = player2dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrame.player2MainCardImage7:SetSize(85, 170)
player2dealtCardsFrame.player2MainCardImage7:SetPoint("LEFT", player2dealtCardsFrame, 562, -7)
player2dealtCardsFrame.player2MainCardImage7:SetBlendMode("BLEND")
player2dealtCardsFrame.player2MainCardImage7:SetDrawLayer("ARTWORK")

player2dealtCardsFrame.playerFirstCardText = player2dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrame.playerFirstCardText:SetPoint("LEFT", player2dealtCardsFrame, 23, -80)
player2dealtCardsFrame.playerFirstCardText:SetJustifyH("CENTER")
player2dealtCardsFrame.playerFirstCardText:SetText("1st Card")
player2dealtCardsFrame.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrame.playerFirstCardText:Hide()

player2dealtCardsFrame.playerSecondCardText = player2dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrame.playerSecondCardText:SetPoint("LEFT", player2dealtCardsFrame, 112, -80)
player2dealtCardsFrame.playerSecondCardText:SetJustifyH("CENTER")
player2dealtCardsFrame.playerSecondCardText:SetText("2nd Card")
player2dealtCardsFrame.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrame.playerSecondCardText:Hide()

player2dealtCardsFrame.playerThirdCardText = player2dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrame.playerThirdCardText:SetPoint("LEFT", player2dealtCardsFrame, 207, -80)
player2dealtCardsFrame.playerThirdCardText:SetJustifyH("CENTER")
player2dealtCardsFrame.playerThirdCardText:SetText("3rd Card")
player2dealtCardsFrame.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrame.playerThirdCardText:Hide()

player2dealtCardsFrame.playerFourthCardText = player2dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrame.playerFourthCardText:SetPoint("LEFT", player2dealtCardsFrame, 299, -80)
player2dealtCardsFrame.playerFourthCardText:SetJustifyH("CENTER")
player2dealtCardsFrame.playerFourthCardText:SetText("4th Card")
player2dealtCardsFrame.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrame.playerFourthCardText:Hide()

player2dealtCardsFrame.playerFifthCardText = player2dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrame.playerFifthCardText:SetPoint("LEFT", player2dealtCardsFrame, 392, -80)
player2dealtCardsFrame.playerFifthCardText:SetJustifyH("CENTER")
player2dealtCardsFrame.playerFifthCardText:SetText("5th Card")
player2dealtCardsFrame.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrame.playerFifthCardText:Hide()

player2dealtCardsFrame.playerSixthCardText = player2dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrame.playerSixthCardText:SetPoint("LEFT", player2dealtCardsFrame, 483, -80)
player2dealtCardsFrame.playerSixthCardText:SetJustifyH("CENTER")
player2dealtCardsFrame.playerSixthCardText:SetText("6th Card")
player2dealtCardsFrame.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrame.playerSixthCardText:Hide()

player2dealtCardsFrame.playerSeventhCardText = player2dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrame.playerSeventhCardText:SetPoint("LEFT", player2dealtCardsFrame, 576, -80)
player2dealtCardsFrame.playerSeventhCardText:SetJustifyH("CENTER")
player2dealtCardsFrame.playerSeventhCardText:SetText("7th Card")
player2dealtCardsFrame.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrame.playerSeventhCardText:Hide()

-- Player H1 Dealt Cards Frame
player2dealtCardsFrameSplitH1= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player2dealtCardsFrameSplitH1:SetSize(656, 200)
player2dealtCardsFrameSplitH1:SetPoint("BOTTOM", playerFrame, 0, 5)
player2dealtCardsFrameSplitH1:SetFrameStrata("HIGH")
player2dealtCardsFrameSplitH1:SetFrameLevel(5)
player2dealtCardsFrameSplitH1:Hide()

-- "Hand 1" button which displays Player's Hand 1 cards
player2dealtCardsFrameSplitH1.playerH1CardsButton = CreateFrame("Button", nil, player2dealtCardsFrameSplitH1, "GameMenuButtonTemplate")
player2dealtCardsFrameSplitH1.playerH1CardsButton:SetPoint("TOPLEFT", player2dealtCardsFrameSplitH1, 8, -8)
player2dealtCardsFrameSplitH1.playerH1CardsButton:SetSize(75, 25)
player2dealtCardsFrameSplitH1.playerH1CardsButton:SetText("Hand 1")
player2dealtCardsFrameSplitH1.playerH1CardsButton:Disable()
player2dealtCardsFrameSplitH1.playerH1CardsButton:Hide()

-- "Hand 2" button which displays Player's Hand 2 cards
player2dealtCardsFrameSplitH1.playerH2CardsButton = CreateFrame("Button", nil, player2dealtCardsFrameSplitH1, "GameMenuButtonTemplate")
player2dealtCardsFrameSplitH1.playerH2CardsButton:SetPoint("TOPLEFT", player2dealtCardsFrameSplitH1, 84, -8)
player2dealtCardsFrameSplitH1.playerH2CardsButton:SetSize(75, 25)
player2dealtCardsFrameSplitH1.playerH2CardsButton:SetText("Hand 2")
player2dealtCardsFrameSplitH1.playerH2CardsButton:Hide()

player2dealtCardsFrameSplitH1.player2H1CardImage1 = player2dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH1.player2H1CardImage1:SetSize(85, 170)
player2dealtCardsFrameSplitH1.player2H1CardImage1:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 10, -7)
player2dealtCardsFrameSplitH1.player2H1CardImage1:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH1.player2H1CardImage1:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH1.player2H1CardImage2 = player2dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH1.player2H1CardImage2:SetSize(85, 170)
player2dealtCardsFrameSplitH1.player2H1CardImage2:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 102, -7)
player2dealtCardsFrameSplitH1.player2H1CardImage2:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH1.player2H1CardImage2:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH1.player2H1CardImage3 = player2dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH1.player2H1CardImage3:SetSize(85, 170)
player2dealtCardsFrameSplitH1.player2H1CardImage3:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 194, -7)
player2dealtCardsFrameSplitH1.player2H1CardImage3:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH1.player2H1CardImage3:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH1.player2H1CardImage4 = player2dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH1.player2H1CardImage4:SetSize(85, 170)
player2dealtCardsFrameSplitH1.player2H1CardImage4:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 286, -7)
player2dealtCardsFrameSplitH1.player2H1CardImage4:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH1.player2H1CardImage4:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH1.player2H1CardImage5 = player2dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH1.player2H1CardImage5:SetSize(85, 170)
player2dealtCardsFrameSplitH1.player2H1CardImage5:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 378, -7)
player2dealtCardsFrameSplitH1.player2H1CardImage5:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH1.player2H1CardImage5:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH1.player2H1CardImage6 = player2dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH1.player2H1CardImage6:SetSize(85, 170)
player2dealtCardsFrameSplitH1.player2H1CardImage6:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 470, -7)
player2dealtCardsFrameSplitH1.player2H1CardImage6:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH1.player2H1CardImage6:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH1.player2H1CardImage7 = player2dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH1.player2H1CardImage7:SetSize(85, 170)
player2dealtCardsFrameSplitH1.player2H1CardImage7:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 562, -7)
player2dealtCardsFrameSplitH1.player2H1CardImage7:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH1.player2H1CardImage7:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH1.playerFirstCardText = player2dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH1.playerFirstCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 23, -80)
player2dealtCardsFrameSplitH1.playerFirstCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH1.playerFirstCardText:SetText("1st Card")
player2dealtCardsFrameSplitH1.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH1.playerFirstCardText:Hide()

player2dealtCardsFrameSplitH1.playerSecondCardText = player2dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH1.playerSecondCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 112, -80)
player2dealtCardsFrameSplitH1.playerSecondCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH1.playerSecondCardText:SetText("2nd Card")
player2dealtCardsFrameSplitH1.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH1.playerSecondCardText:Hide()

player2dealtCardsFrameSplitH1.playerThirdCardText = player2dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH1.playerThirdCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 207, -80)
player2dealtCardsFrameSplitH1.playerThirdCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH1.playerThirdCardText:SetText("3rd Card")
player2dealtCardsFrameSplitH1.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH1.playerThirdCardText:Hide()

player2dealtCardsFrameSplitH1.playerFourthCardText = player2dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH1.playerFourthCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 299, -80)
player2dealtCardsFrameSplitH1.playerFourthCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH1.playerFourthCardText:SetText("4th Card")
player2dealtCardsFrameSplitH1.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH1.playerFourthCardText:Hide()

player2dealtCardsFrameSplitH1.playerFifthCardText = player2dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH1.playerFifthCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 392, -80)
player2dealtCardsFrameSplitH1.playerFifthCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH1.playerFifthCardText:SetText("5th Card")
player2dealtCardsFrameSplitH1.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH1.playerFifthCardText:Hide()

player2dealtCardsFrameSplitH1.playerSixthCardText = player2dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH1.playerSixthCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 483, -80)
player2dealtCardsFrameSplitH1.playerSixthCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH1.playerSixthCardText:SetText("6th Card")
player2dealtCardsFrameSplitH1.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH1.playerSixthCardText:Hide()

player2dealtCardsFrameSplitH1.playerSeventhCardText = player2dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH1.playerSeventhCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH1, 576, -80)
player2dealtCardsFrameSplitH1.playerSeventhCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH1.playerSeventhCardText:SetText("7th Card")
player2dealtCardsFrameSplitH1.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH1.playerSeventhCardText:Hide()

-- Player H2 Dealt Cards Frame
player2dealtCardsFrameSplitH2= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player2dealtCardsFrameSplitH2:SetSize(656, 200)
player2dealtCardsFrameSplitH2:SetPoint("BOTTOM", playerFrame, 0, 5)
player2dealtCardsFrameSplitH2:SetFrameStrata("HIGH")
player2dealtCardsFrameSplitH2:SetFrameLevel(5)
player2dealtCardsFrameSplitH2:Hide()

-- "Hand 1" button which displays Player's Hand 1 cards
player2dealtCardsFrameSplitH2.playerH1CardsButton = CreateFrame("Button", nil, player2dealtCardsFrameSplitH2, "GameMenuButtonTemplate")
player2dealtCardsFrameSplitH2.playerH1CardsButton:SetPoint("TOPLEFT", player2dealtCardsFrameSplitH2, 8, -8)
player2dealtCardsFrameSplitH2.playerH1CardsButton:SetSize(75, 25)
player2dealtCardsFrameSplitH2.playerH1CardsButton:SetText("Hand 1")
player2dealtCardsFrameSplitH2.playerH1CardsButton:Hide()

-- "Hand 2" button which displays Player's Hand 2 cards
player2dealtCardsFrameSplitH2.playerH2CardsButton = CreateFrame("Button", nil, player2dealtCardsFrameSplitH2, "GameMenuButtonTemplate")
player2dealtCardsFrameSplitH2.playerH2CardsButton:SetPoint("TOPLEFT", player2dealtCardsFrameSplitH2, 84, -8)
player2dealtCardsFrameSplitH2.playerH2CardsButton:SetSize(75, 25)
player2dealtCardsFrameSplitH2.playerH2CardsButton:SetText("Hand 2")
player2dealtCardsFrameSplitH2.playerH2CardsButton:Disable()
player2dealtCardsFrameSplitH2.playerH2CardsButton:Hide()

player2dealtCardsFrameSplitH2.player2H2CardImage1 = player2dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH2.player2H2CardImage1:SetSize(85, 170)
player2dealtCardsFrameSplitH2.player2H2CardImage1:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 10, -7)
player2dealtCardsFrameSplitH2.player2H2CardImage1:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH2.player2H2CardImage1:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH2.player2H2CardImage2 = player2dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH2.player2H2CardImage2:SetSize(85, 170)
player2dealtCardsFrameSplitH2.player2H2CardImage2:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 102, -7)
player2dealtCardsFrameSplitH2.player2H2CardImage2:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH2.player2H2CardImage2:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH2.player2H2CardImage3 = player2dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH2.player2H2CardImage3:SetSize(85, 170)
player2dealtCardsFrameSplitH2.player2H2CardImage3:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 194, -7)
player2dealtCardsFrameSplitH2.player2H2CardImage3:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH2.player2H2CardImage3:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH2.player2H2CardImage4 = player2dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH2.player2H2CardImage4:SetSize(85, 170)
player2dealtCardsFrameSplitH2.player2H2CardImage4:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 286, -7)
player2dealtCardsFrameSplitH2.player2H2CardImage4:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH2.player2H2CardImage4:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH2.player2H2CardImage5 = player2dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH2.player2H2CardImage5:SetSize(85, 170)
player2dealtCardsFrameSplitH2.player2H2CardImage5:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 378, -7)
player2dealtCardsFrameSplitH2.player2H2CardImage5:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH2.player2H2CardImage5:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH2.player2H2CardImage6 = player2dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH2.player2H2CardImage6:SetSize(85, 170)
player2dealtCardsFrameSplitH2.player2H2CardImage6:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 470, -7)
player2dealtCardsFrameSplitH2.player2H2CardImage6:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH2.player2H2CardImage6:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH2.player2H2CardImage7 = player2dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player2dealtCardsFrameSplitH2.player2H2CardImage7:SetSize(85, 170)
player2dealtCardsFrameSplitH2.player2H2CardImage7:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 562, -7)
player2dealtCardsFrameSplitH2.player2H2CardImage7:SetBlendMode("BLEND")
player2dealtCardsFrameSplitH2.player2H2CardImage7:SetDrawLayer("ARTWORK")

player2dealtCardsFrameSplitH2.playerFirstCardText = player2dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH2.playerFirstCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 23, -80)
player2dealtCardsFrameSplitH2.playerFirstCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH2.playerFirstCardText:SetText("1st Card")
player2dealtCardsFrameSplitH2.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH2.playerFirstCardText:Hide()

player2dealtCardsFrameSplitH2.playerSecondCardText = player2dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH2.playerSecondCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 112, -80)
player2dealtCardsFrameSplitH2.playerSecondCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH2.playerSecondCardText:SetText("2nd Card")
player2dealtCardsFrameSplitH2.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH2.playerSecondCardText:Hide()

player2dealtCardsFrameSplitH2.playerThirdCardText = player2dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH2.playerThirdCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 207, -80)
player2dealtCardsFrameSplitH2.playerThirdCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH2.playerThirdCardText:SetText("3rd Card")
player2dealtCardsFrameSplitH2.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH2.playerThirdCardText:Hide()

player2dealtCardsFrameSplitH2.playerFourthCardText = player2dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH2.playerFourthCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 299, -80)
player2dealtCardsFrameSplitH2.playerFourthCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH2.playerFourthCardText:SetText("4th Card")
player2dealtCardsFrameSplitH2.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH2.playerFourthCardText:Hide()

player2dealtCardsFrameSplitH2.playerFifthCardText = player2dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH2.playerFifthCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 392, -80)
player2dealtCardsFrameSplitH2.playerFifthCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH2.playerFifthCardText:SetText("5th Card")
player2dealtCardsFrameSplitH2.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH2.playerFifthCardText:Hide()

player2dealtCardsFrameSplitH2.playerSixthCardText = player2dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH2.playerSixthCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 483, -80)
player2dealtCardsFrameSplitH2.playerSixthCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH2.playerSixthCardText:SetText("6th Card")
player2dealtCardsFrameSplitH2.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH2.playerSixthCardText:Hide()

player2dealtCardsFrameSplitH2.playerSeventhCardText = player2dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2dealtCardsFrameSplitH2.playerSeventhCardText:SetPoint("LEFT", player2dealtCardsFrameSplitH2, 576, -80)
player2dealtCardsFrameSplitH2.playerSeventhCardText:SetJustifyH("CENTER")
player2dealtCardsFrameSplitH2.playerSeventhCardText:SetText("7th Card")
player2dealtCardsFrameSplitH2.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2dealtCardsFrameSplitH2.playerSeventhCardText:Hide()







-- >> PLAYER 3 <<
-- >> PLAYER 3 <<
-- >> PLAYER 3 <<

-- Player Dealt Cards Frame
player3dealtCardsFrame= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player3dealtCardsFrame:SetSize(656, 200)
player3dealtCardsFrame:SetPoint("BOTTOM", playerFrame, 0, 5)
player3dealtCardsFrame:SetFrameStrata("HIGH")
player3dealtCardsFrame:SetFrameLevel(6)
player3dealtCardsFrame:Hide()

-- "Player" button which displays Player's Main Hand cards
player3dealtCardsFrame.playerCardsButton = CreateFrame("Button", nil, player3dealtCardsFrame, "GameMenuButtonTemplate")
player3dealtCardsFrame.playerCardsButton:SetPoint("TOPLEFT", player3dealtCardsFrame, 8, -8)
player3dealtCardsFrame.playerCardsButton:SetSize(75, 25)
player3dealtCardsFrame.playerCardsButton:SetText("Player")
player3dealtCardsFrame.playerCardsButton:Disable()
player3dealtCardsFrame.playerCardsButton:Hide()

player3dealtCardsFrame.notStartedYetText = player3dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrame.notStartedYetText:SetPoint("CENTER", player3dealtCardsFrame, 0, 0)
player3dealtCardsFrame.notStartedYetText:SetJustifyH("CENTER")
player3dealtCardsFrame.notStartedYetText:SetText("The round hasn't started yet")
player3dealtCardsFrame.notStartedYetText:SetFont("Fonts\\FRIZQT__.TTF", 20, "OUTLINE")
player3dealtCardsFrame.notStartedYetText:Hide()

player3dealtCardsFrame.player3MainCardImage1 = player3dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrame.player3MainCardImage1:SetSize(85, 170)
player3dealtCardsFrame.player3MainCardImage1:SetPoint("LEFT", player3dealtCardsFrame, 10, -7)
player3dealtCardsFrame.player3MainCardImage1:SetBlendMode("BLEND")
player3dealtCardsFrame.player3MainCardImage1:SetDrawLayer("ARTWORK")

player3dealtCardsFrame.player3MainCardImage2 = player3dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrame.player3MainCardImage2:SetSize(85, 170)
player3dealtCardsFrame.player3MainCardImage2:SetPoint("LEFT", player3dealtCardsFrame, 102, -7)
player3dealtCardsFrame.player3MainCardImage2:SetBlendMode("BLEND")
player3dealtCardsFrame.player3MainCardImage2:SetDrawLayer("ARTWORK")

player3dealtCardsFrame.player3MainCardImage3 = player3dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrame.player3MainCardImage3:SetSize(85, 170)
player3dealtCardsFrame.player3MainCardImage3:SetPoint("LEFT", player3dealtCardsFrame, 194, -7)
player3dealtCardsFrame.player3MainCardImage3:SetBlendMode("BLEND")
player3dealtCardsFrame.player3MainCardImage3:SetDrawLayer("ARTWORK")

player3dealtCardsFrame.player3MainCardImage4 = player3dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrame.player3MainCardImage4:SetSize(85, 170)
player3dealtCardsFrame.player3MainCardImage4:SetPoint("LEFT", player3dealtCardsFrame, 286, -7)
player3dealtCardsFrame.player3MainCardImage4:SetBlendMode("BLEND")
player3dealtCardsFrame.player3MainCardImage4:SetDrawLayer("ARTWORK")

player3dealtCardsFrame.player3MainCardImage5 = player3dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrame.player3MainCardImage5:SetSize(85, 170)
player3dealtCardsFrame.player3MainCardImage5:SetPoint("LEFT", player3dealtCardsFrame, 378, -7)
player3dealtCardsFrame.player3MainCardImage5:SetBlendMode("BLEND")
player3dealtCardsFrame.player3MainCardImage5:SetDrawLayer("ARTWORK")

player3dealtCardsFrame.player3MainCardImage6 = player3dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrame.player3MainCardImage6:SetSize(85, 170)
player3dealtCardsFrame.player3MainCardImage6:SetPoint("LEFT", player3dealtCardsFrame, 470, -7)
player3dealtCardsFrame.player3MainCardImage6:SetBlendMode("BLEND")
player3dealtCardsFrame.player3MainCardImage6:SetDrawLayer("ARTWORK")

player3dealtCardsFrame.player3MainCardImage7 = player3dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrame.player3MainCardImage7:SetSize(85, 170)
player3dealtCardsFrame.player3MainCardImage7:SetPoint("LEFT", player3dealtCardsFrame, 562, -7)
player3dealtCardsFrame.player3MainCardImage7:SetBlendMode("BLEND")
player3dealtCardsFrame.player3MainCardImage7:SetDrawLayer("ARTWORK")

player3dealtCardsFrame.playerFirstCardText = player3dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrame.playerFirstCardText:SetPoint("LEFT", player3dealtCardsFrame, 23, -80)
player3dealtCardsFrame.playerFirstCardText:SetJustifyH("CENTER")
player3dealtCardsFrame.playerFirstCardText:SetText("1st Card")
player3dealtCardsFrame.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrame.playerFirstCardText:Hide()

player3dealtCardsFrame.playerSecondCardText = player3dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrame.playerSecondCardText:SetPoint("LEFT", player3dealtCardsFrame, 112, -80)
player3dealtCardsFrame.playerSecondCardText:SetJustifyH("CENTER")
player3dealtCardsFrame.playerSecondCardText:SetText("2nd Card")
player3dealtCardsFrame.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrame.playerSecondCardText:Hide()

player3dealtCardsFrame.playerThirdCardText = player3dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrame.playerThirdCardText:SetPoint("LEFT", player3dealtCardsFrame, 207, -80)
player3dealtCardsFrame.playerThirdCardText:SetJustifyH("CENTER")
player3dealtCardsFrame.playerThirdCardText:SetText("3rd Card")
player3dealtCardsFrame.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrame.playerThirdCardText:Hide()

player3dealtCardsFrame.playerFourthCardText = player3dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrame.playerFourthCardText:SetPoint("LEFT", player3dealtCardsFrame, 299, -80)
player3dealtCardsFrame.playerFourthCardText:SetJustifyH("CENTER")
player3dealtCardsFrame.playerFourthCardText:SetText("4th Card")
player3dealtCardsFrame.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrame.playerFourthCardText:Hide()

player3dealtCardsFrame.playerFifthCardText = player3dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrame.playerFifthCardText:SetPoint("LEFT", player3dealtCardsFrame, 392, -80)
player3dealtCardsFrame.playerFifthCardText:SetJustifyH("CENTER")
player3dealtCardsFrame.playerFifthCardText:SetText("5th Card")
player3dealtCardsFrame.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrame.playerFifthCardText:Hide()

player3dealtCardsFrame.playerSixthCardText = player3dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrame.playerSixthCardText:SetPoint("LEFT", player3dealtCardsFrame, 483, -80)
player3dealtCardsFrame.playerSixthCardText:SetJustifyH("CENTER")
player3dealtCardsFrame.playerSixthCardText:SetText("6th Card")
player3dealtCardsFrame.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrame.playerSixthCardText:Hide()

player3dealtCardsFrame.playerSeventhCardText = player3dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrame.playerSeventhCardText:SetPoint("LEFT", player3dealtCardsFrame, 576, -80)
player3dealtCardsFrame.playerSeventhCardText:SetJustifyH("CENTER")
player3dealtCardsFrame.playerSeventhCardText:SetText("7th Card")
player3dealtCardsFrame.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrame.playerSeventhCardText:Hide()

-- Player H1 Dealt Cards Frame
player3dealtCardsFrameSplitH1= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player3dealtCardsFrameSplitH1:SetSize(656, 200)
player3dealtCardsFrameSplitH1:SetPoint("BOTTOM", playerFrame, 0, 5)
player3dealtCardsFrameSplitH1:SetFrameStrata("HIGH")
player3dealtCardsFrameSplitH1:SetFrameLevel(5)
player3dealtCardsFrameSplitH1:Hide()

-- "Hand 1" button which displays Player's Hand 1 cards
player3dealtCardsFrameSplitH1.playerH1CardsButton = CreateFrame("Button", nil, player3dealtCardsFrameSplitH1, "GameMenuButtonTemplate")
player3dealtCardsFrameSplitH1.playerH1CardsButton:SetPoint("TOPLEFT", player3dealtCardsFrameSplitH1, 8, -8)
player3dealtCardsFrameSplitH1.playerH1CardsButton:SetSize(75, 25)
player3dealtCardsFrameSplitH1.playerH1CardsButton:SetText("Hand 1")
player3dealtCardsFrameSplitH1.playerH1CardsButton:Disable()
player3dealtCardsFrameSplitH1.playerH1CardsButton:Hide()

-- "Hand 2" button which displays Player's Hand 2 cards
player3dealtCardsFrameSplitH1.playerH2CardsButton = CreateFrame("Button", nil, player3dealtCardsFrameSplitH1, "GameMenuButtonTemplate")
player3dealtCardsFrameSplitH1.playerH2CardsButton:SetPoint("TOPLEFT", player3dealtCardsFrameSplitH1, 84, -8)
player3dealtCardsFrameSplitH1.playerH2CardsButton:SetSize(75, 25)
player3dealtCardsFrameSplitH1.playerH2CardsButton:SetText("Hand 2")
player3dealtCardsFrameSplitH1.playerH2CardsButton:Hide()

player3dealtCardsFrameSplitH1.player3H1CardImage1 = player3dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH1.player3H1CardImage1:SetSize(85, 170)
player3dealtCardsFrameSplitH1.player3H1CardImage1:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 10, -7)
player3dealtCardsFrameSplitH1.player3H1CardImage1:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH1.player3H1CardImage1:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH1.player3H1CardImage2 = player3dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH1.player3H1CardImage2:SetSize(85, 170)
player3dealtCardsFrameSplitH1.player3H1CardImage2:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 102, -7)
player3dealtCardsFrameSplitH1.player3H1CardImage2:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH1.player3H1CardImage2:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH1.player3H1CardImage3 = player3dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH1.player3H1CardImage3:SetSize(85, 170)
player3dealtCardsFrameSplitH1.player3H1CardImage3:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 194, -7)
player3dealtCardsFrameSplitH1.player3H1CardImage3:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH1.player3H1CardImage3:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH1.player3H1CardImage4 = player3dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH1.player3H1CardImage4:SetSize(85, 170)
player3dealtCardsFrameSplitH1.player3H1CardImage4:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 286, -7)
player3dealtCardsFrameSplitH1.player3H1CardImage4:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH1.player3H1CardImage4:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH1.player3H1CardImage5 = player3dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH1.player3H1CardImage5:SetSize(85, 170)
player3dealtCardsFrameSplitH1.player3H1CardImage5:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 378, -7)
player3dealtCardsFrameSplitH1.player3H1CardImage5:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH1.player3H1CardImage5:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH1.player3H1CardImage6 = player3dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH1.player3H1CardImage6:SetSize(85, 170)
player3dealtCardsFrameSplitH1.player3H1CardImage6:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 470, -7)
player3dealtCardsFrameSplitH1.player3H1CardImage6:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH1.player3H1CardImage6:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH1.player3H1CardImage7 = player3dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH1.player3H1CardImage7:SetSize(85, 170)
player3dealtCardsFrameSplitH1.player3H1CardImage7:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 562, -7)
player3dealtCardsFrameSplitH1.player3H1CardImage7:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH1.player3H1CardImage7:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH1.playerFirstCardText = player3dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH1.playerFirstCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 23, -80)
player3dealtCardsFrameSplitH1.playerFirstCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH1.playerFirstCardText:SetText("1st Card")
player3dealtCardsFrameSplitH1.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH1.playerFirstCardText:Hide()

player3dealtCardsFrameSplitH1.playerSecondCardText = player3dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH1.playerSecondCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 112, -80)
player3dealtCardsFrameSplitH1.playerSecondCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH1.playerSecondCardText:SetText("2nd Card")
player3dealtCardsFrameSplitH1.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH1.playerSecondCardText:Hide()

player3dealtCardsFrameSplitH1.playerThirdCardText = player3dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH1.playerThirdCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 207, -80)
player3dealtCardsFrameSplitH1.playerThirdCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH1.playerThirdCardText:SetText("3rd Card")
player3dealtCardsFrameSplitH1.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH1.playerThirdCardText:Hide()

player3dealtCardsFrameSplitH1.playerFourthCardText = player3dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH1.playerFourthCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 299, -80)
player3dealtCardsFrameSplitH1.playerFourthCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH1.playerFourthCardText:SetText("4th Card")
player3dealtCardsFrameSplitH1.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH1.playerFourthCardText:Hide()

player3dealtCardsFrameSplitH1.playerFifthCardText = player3dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH1.playerFifthCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 392, -80)
player3dealtCardsFrameSplitH1.playerFifthCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH1.playerFifthCardText:SetText("5th Card")
player3dealtCardsFrameSplitH1.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH1.playerFifthCardText:Hide()

player3dealtCardsFrameSplitH1.playerSixthCardText = player3dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH1.playerSixthCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 483, -80)
player3dealtCardsFrameSplitH1.playerSixthCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH1.playerSixthCardText:SetText("6th Card")
player3dealtCardsFrameSplitH1.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH1.playerSixthCardText:Hide()

player3dealtCardsFrameSplitH1.playerSeventhCardText = player3dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH1.playerSeventhCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH1, 576, -80)
player3dealtCardsFrameSplitH1.playerSeventhCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH1.playerSeventhCardText:SetText("7th Card")
player3dealtCardsFrameSplitH1.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH1.playerSeventhCardText:Hide()

-- Player H2 Dealt Cards Frame
player3dealtCardsFrameSplitH2= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player3dealtCardsFrameSplitH2:SetSize(656, 200)
player3dealtCardsFrameSplitH2:SetPoint("BOTTOM", playerFrame, 0, 5)
player3dealtCardsFrameSplitH2:SetFrameStrata("HIGH")
player3dealtCardsFrameSplitH2:SetFrameLevel(5)
player3dealtCardsFrameSplitH2:Hide()

-- "Hand 1" button which displays Player's Hand 1 cards
player3dealtCardsFrameSplitH2.playerH1CardsButton = CreateFrame("Button", nil, player3dealtCardsFrameSplitH2, "GameMenuButtonTemplate")
player3dealtCardsFrameSplitH2.playerH1CardsButton:SetPoint("TOPLEFT", player3dealtCardsFrameSplitH2, 8, -8)
player3dealtCardsFrameSplitH2.playerH1CardsButton:SetSize(75, 25)
player3dealtCardsFrameSplitH2.playerH1CardsButton:SetText("Hand 1")
player3dealtCardsFrameSplitH2.playerH1CardsButton:Hide()

-- "Hand 2" button which displays Player's Hand 2 cards
player3dealtCardsFrameSplitH2.playerH2CardsButton = CreateFrame("Button", nil, player3dealtCardsFrameSplitH2, "GameMenuButtonTemplate")
player3dealtCardsFrameSplitH2.playerH2CardsButton:SetPoint("TOPLEFT", player3dealtCardsFrameSplitH2, 84, -8)
player3dealtCardsFrameSplitH2.playerH2CardsButton:SetSize(75, 25)
player3dealtCardsFrameSplitH2.playerH2CardsButton:SetText("Hand 2")
player3dealtCardsFrameSplitH2.playerH2CardsButton:Disable()
player3dealtCardsFrameSplitH2.playerH2CardsButton:Hide()

player3dealtCardsFrameSplitH2.player3H2CardImage1 = player3dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH2.player3H2CardImage1:SetSize(85, 170)
player3dealtCardsFrameSplitH2.player3H2CardImage1:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 10, -7)
player3dealtCardsFrameSplitH2.player3H2CardImage1:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH2.player3H2CardImage1:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH2.player3H2CardImage2 = player3dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH2.player3H2CardImage2:SetSize(85, 170)
player3dealtCardsFrameSplitH2.player3H2CardImage2:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 102, -7)
player3dealtCardsFrameSplitH2.player3H2CardImage2:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH2.player3H2CardImage2:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH2.player3H2CardImage3 = player3dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH2.player3H2CardImage3:SetSize(85, 170)
player3dealtCardsFrameSplitH2.player3H2CardImage3:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 194, -7)
player3dealtCardsFrameSplitH2.player3H2CardImage3:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH2.player3H2CardImage3:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH2.player3H2CardImage4 = player3dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH2.player3H2CardImage4:SetSize(85, 170)
player3dealtCardsFrameSplitH2.player3H2CardImage4:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 286, -7)
player3dealtCardsFrameSplitH2.player3H2CardImage4:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH2.player3H2CardImage4:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH2.player3H2CardImage5 = player3dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH2.player3H2CardImage5:SetSize(85, 170)
player3dealtCardsFrameSplitH2.player3H2CardImage5:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 378, -7)
player3dealtCardsFrameSplitH2.player3H2CardImage5:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH2.player3H2CardImage5:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH2.player3H2CardImage6 = player3dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH2.player3H2CardImage6:SetSize(85, 170)
player3dealtCardsFrameSplitH2.player3H2CardImage6:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 470, -7)
player3dealtCardsFrameSplitH2.player3H2CardImage6:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH2.player3H2CardImage6:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH2.player3H2CardImage7 = player3dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player3dealtCardsFrameSplitH2.player3H2CardImage7:SetSize(85, 170)
player3dealtCardsFrameSplitH2.player3H2CardImage7:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 562, -7)
player3dealtCardsFrameSplitH2.player3H2CardImage7:SetBlendMode("BLEND")
player3dealtCardsFrameSplitH2.player3H2CardImage7:SetDrawLayer("ARTWORK")

player3dealtCardsFrameSplitH2.playerFirstCardText = player3dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH2.playerFirstCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 23, -80)
player3dealtCardsFrameSplitH2.playerFirstCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH2.playerFirstCardText:SetText("1st Card")
player3dealtCardsFrameSplitH2.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH2.playerFirstCardText:Hide()

player3dealtCardsFrameSplitH2.playerSecondCardText = player3dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH2.playerSecondCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 112, -80)
player3dealtCardsFrameSplitH2.playerSecondCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH2.playerSecondCardText:SetText("2nd Card")
player3dealtCardsFrameSplitH2.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH2.playerSecondCardText:Hide()

player3dealtCardsFrameSplitH2.playerThirdCardText = player3dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH2.playerThirdCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 207, -80)
player3dealtCardsFrameSplitH2.playerThirdCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH2.playerThirdCardText:SetText("3rd Card")
player3dealtCardsFrameSplitH2.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH2.playerThirdCardText:Hide()

player3dealtCardsFrameSplitH2.playerFourthCardText = player3dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH2.playerFourthCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 299, -80)
player3dealtCardsFrameSplitH2.playerFourthCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH2.playerFourthCardText:SetText("4th Card")
player3dealtCardsFrameSplitH2.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH2.playerFourthCardText:Hide()

player3dealtCardsFrameSplitH2.playerFifthCardText = player3dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH2.playerFifthCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 392, -80)
player3dealtCardsFrameSplitH2.playerFifthCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH2.playerFifthCardText:SetText("5th Card")
player3dealtCardsFrameSplitH2.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH2.playerFifthCardText:Hide()

player3dealtCardsFrameSplitH2.playerSixthCardText = player3dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH2.playerSixthCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 483, -80)
player3dealtCardsFrameSplitH2.playerSixthCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH2.playerSixthCardText:SetText("6th Card")
player3dealtCardsFrameSplitH2.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH2.playerSixthCardText:Hide()

player3dealtCardsFrameSplitH2.playerSeventhCardText = player3dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3dealtCardsFrameSplitH2.playerSeventhCardText:SetPoint("LEFT", player3dealtCardsFrameSplitH2, 576, -80)
player3dealtCardsFrameSplitH2.playerSeventhCardText:SetJustifyH("CENTER")
player3dealtCardsFrameSplitH2.playerSeventhCardText:SetText("7th Card")
player3dealtCardsFrameSplitH2.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3dealtCardsFrameSplitH2.playerSeventhCardText:Hide()






-- >> PLAYER 4 <<
-- >> PLAYER 4 <<
-- >> PLAYER 4 <<

-- Player Dealt Cards Frame
player4dealtCardsFrame= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player4dealtCardsFrame:SetSize(656, 200)
player4dealtCardsFrame:SetPoint("BOTTOM", playerFrame, 0, 5)
player4dealtCardsFrame:SetFrameStrata("HIGH")
player4dealtCardsFrame:SetFrameLevel(6)
player4dealtCardsFrame:Hide()

-- "Player" button which displays Player's Main Hand cards
player4dealtCardsFrame.playerCardsButton = CreateFrame("Button", nil, player4dealtCardsFrame, "GameMenuButtonTemplate")
player4dealtCardsFrame.playerCardsButton:SetPoint("TOPLEFT", player4dealtCardsFrame, 8, -8)
player4dealtCardsFrame.playerCardsButton:SetSize(75, 25)
player4dealtCardsFrame.playerCardsButton:SetText("Player")
player4dealtCardsFrame.playerCardsButton:Disable()
player4dealtCardsFrame.playerCardsButton:Hide()


player4dealtCardsFrame.notStartedYetText = player4dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrame.notStartedYetText:SetPoint("CENTER", player4dealtCardsFrame, 0, 0)
player4dealtCardsFrame.notStartedYetText:SetJustifyH("CENTER")
player4dealtCardsFrame.notStartedYetText:SetText("The round hasn't started yet")
player4dealtCardsFrame.notStartedYetText:SetFont("Fonts\\FRIZQT__.TTF", 20, "OUTLINE")
player4dealtCardsFrame.notStartedYetText:Hide()

player4dealtCardsFrame.player4MainCardImage1 = player4dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrame.player4MainCardImage1:SetSize(85, 170)
player4dealtCardsFrame.player4MainCardImage1:SetPoint("LEFT", player4dealtCardsFrame, 10, -7)
player4dealtCardsFrame.player4MainCardImage1:SetBlendMode("BLEND")
player4dealtCardsFrame.player4MainCardImage1:SetDrawLayer("ARTWORK")

player4dealtCardsFrame.player4MainCardImage2 = player4dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrame.player4MainCardImage2:SetSize(85, 170)
player4dealtCardsFrame.player4MainCardImage2:SetPoint("LEFT", player4dealtCardsFrame, 102, -7)
player4dealtCardsFrame.player4MainCardImage2:SetBlendMode("BLEND")
player4dealtCardsFrame.player4MainCardImage2:SetDrawLayer("ARTWORK")

player4dealtCardsFrame.player4MainCardImage3 = player4dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrame.player4MainCardImage3:SetSize(85, 170)
player4dealtCardsFrame.player4MainCardImage3:SetPoint("LEFT", player4dealtCardsFrame, 194, -7)
player4dealtCardsFrame.player4MainCardImage3:SetBlendMode("BLEND")
player4dealtCardsFrame.player4MainCardImage3:SetDrawLayer("ARTWORK")

player4dealtCardsFrame.player4MainCardImage4 = player4dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrame.player4MainCardImage4:SetSize(85, 170)
player4dealtCardsFrame.player4MainCardImage4:SetPoint("LEFT", player4dealtCardsFrame, 286, -7)
player4dealtCardsFrame.player4MainCardImage4:SetBlendMode("BLEND")
player4dealtCardsFrame.player4MainCardImage4:SetDrawLayer("ARTWORK")

player4dealtCardsFrame.player4MainCardImage5 = player4dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrame.player4MainCardImage5:SetSize(85, 170)
player4dealtCardsFrame.player4MainCardImage5:SetPoint("LEFT", player4dealtCardsFrame, 378, -7)
player4dealtCardsFrame.player4MainCardImage5:SetBlendMode("BLEND")
player4dealtCardsFrame.player4MainCardImage5:SetDrawLayer("ARTWORK")

player4dealtCardsFrame.player4MainCardImage6 = player4dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrame.player4MainCardImage6:SetSize(85, 170)
player4dealtCardsFrame.player4MainCardImage6:SetPoint("LEFT", player4dealtCardsFrame, 470, -7)
player4dealtCardsFrame.player4MainCardImage6:SetBlendMode("BLEND")
player4dealtCardsFrame.player4MainCardImage6:SetDrawLayer("ARTWORK")

player4dealtCardsFrame.player4MainCardImage7 = player4dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrame.player4MainCardImage7:SetSize(85, 170)
player4dealtCardsFrame.player4MainCardImage7:SetPoint("LEFT", player4dealtCardsFrame, 562, -7)
player4dealtCardsFrame.player4MainCardImage7:SetBlendMode("BLEND")
player4dealtCardsFrame.player4MainCardImage7:SetDrawLayer("ARTWORK")

player4dealtCardsFrame.playerFirstCardText = player4dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrame.playerFirstCardText:SetPoint("LEFT", player4dealtCardsFrame, 23, -80)
player4dealtCardsFrame.playerFirstCardText:SetJustifyH("CENTER")
player4dealtCardsFrame.playerFirstCardText:SetText("1st Card")
player4dealtCardsFrame.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrame.playerFirstCardText:Hide()

player4dealtCardsFrame.playerSecondCardText = player4dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrame.playerSecondCardText:SetPoint("LEFT", player4dealtCardsFrame, 112, -80)
player4dealtCardsFrame.playerSecondCardText:SetJustifyH("CENTER")
player4dealtCardsFrame.playerSecondCardText:SetText("2nd Card")
player4dealtCardsFrame.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrame.playerSecondCardText:Hide()

player4dealtCardsFrame.playerThirdCardText = player4dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrame.playerThirdCardText:SetPoint("LEFT", player4dealtCardsFrame, 207, -80)
player4dealtCardsFrame.playerThirdCardText:SetJustifyH("CENTER")
player4dealtCardsFrame.playerThirdCardText:SetText("3rd Card")
player4dealtCardsFrame.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrame.playerThirdCardText:Hide()

player4dealtCardsFrame.playerFourthCardText = player4dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrame.playerFourthCardText:SetPoint("LEFT", player4dealtCardsFrame, 299, -80)
player4dealtCardsFrame.playerFourthCardText:SetJustifyH("CENTER")
player4dealtCardsFrame.playerFourthCardText:SetText("4th Card")
player4dealtCardsFrame.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrame.playerFourthCardText:Hide()

player4dealtCardsFrame.playerFifthCardText = player4dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrame.playerFifthCardText:SetPoint("LEFT", player4dealtCardsFrame, 392, -80)
player4dealtCardsFrame.playerFifthCardText:SetJustifyH("CENTER")
player4dealtCardsFrame.playerFifthCardText:SetText("5th Card")
player4dealtCardsFrame.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrame.playerFifthCardText:Hide()

player4dealtCardsFrame.playerSixthCardText = player4dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrame.playerSixthCardText:SetPoint("LEFT", player4dealtCardsFrame, 483, -80)
player4dealtCardsFrame.playerSixthCardText:SetJustifyH("CENTER")
player4dealtCardsFrame.playerSixthCardText:SetText("6th Card")
player4dealtCardsFrame.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrame.playerSixthCardText:Hide()

player4dealtCardsFrame.playerSeventhCardText = player4dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrame.playerSeventhCardText:SetPoint("LEFT", player4dealtCardsFrame, 576, -80)
player4dealtCardsFrame.playerSeventhCardText:SetJustifyH("CENTER")
player4dealtCardsFrame.playerSeventhCardText:SetText("7th Card")
player4dealtCardsFrame.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrame.playerSeventhCardText:Hide()

-- Player H1 Dealt Cards Frame
player4dealtCardsFrameSplitH1= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player4dealtCardsFrameSplitH1:SetSize(656, 200)
player4dealtCardsFrameSplitH1:SetPoint("BOTTOM", playerFrame, 0, 5)
player4dealtCardsFrameSplitH1:SetFrameStrata("HIGH")
player4dealtCardsFrameSplitH1:SetFrameLevel(5)
player4dealtCardsFrameSplitH1:Hide()

-- "Hand 1" button which displays Player's Hand 1 cards
player4dealtCardsFrameSplitH1.playerH1CardsButton = CreateFrame("Button", nil, player4dealtCardsFrameSplitH1, "GameMenuButtonTemplate")
player4dealtCardsFrameSplitH1.playerH1CardsButton:SetPoint("TOPLEFT", player4dealtCardsFrameSplitH1, 8, -8)
player4dealtCardsFrameSplitH1.playerH1CardsButton:SetSize(75, 25)
player4dealtCardsFrameSplitH1.playerH1CardsButton:SetText("Hand 1")
player4dealtCardsFrameSplitH1.playerH1CardsButton:Disable()
player4dealtCardsFrameSplitH1.playerH1CardsButton:Hide()

-- "Hand 2" button which displays Player's Hand 2 cards
player4dealtCardsFrameSplitH1.playerH2CardsButton = CreateFrame("Button", nil, player4dealtCardsFrameSplitH1, "GameMenuButtonTemplate")
player4dealtCardsFrameSplitH1.playerH2CardsButton:SetPoint("TOPLEFT", player4dealtCardsFrameSplitH1, 84, -8)
player4dealtCardsFrameSplitH1.playerH2CardsButton:SetSize(75, 25)
player4dealtCardsFrameSplitH1.playerH2CardsButton:SetText("Hand 2")
player4dealtCardsFrameSplitH1.playerH2CardsButton:Hide()

player4dealtCardsFrameSplitH1.player4H1CardImage1 = player4dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH1.player4H1CardImage1:SetSize(85, 170)
player4dealtCardsFrameSplitH1.player4H1CardImage1:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 10, -7)
player4dealtCardsFrameSplitH1.player4H1CardImage1:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH1.player4H1CardImage1:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH1.player4H1CardImage2 = player4dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH1.player4H1CardImage2:SetSize(85, 170)
player4dealtCardsFrameSplitH1.player4H1CardImage2:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 102, -7)
player4dealtCardsFrameSplitH1.player4H1CardImage2:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH1.player4H1CardImage2:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH1.player4H1CardImage3 = player4dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH1.player4H1CardImage3:SetSize(85, 170)
player4dealtCardsFrameSplitH1.player4H1CardImage3:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 194, -7)
player4dealtCardsFrameSplitH1.player4H1CardImage3:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH1.player4H1CardImage3:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH1.player4H1CardImage4 = player4dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH1.player4H1CardImage4:SetSize(85, 170)
player4dealtCardsFrameSplitH1.player4H1CardImage4:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 286, -7)
player4dealtCardsFrameSplitH1.player4H1CardImage4:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH1.player4H1CardImage4:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH1.player4H1CardImage5 = player4dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH1.player4H1CardImage5:SetSize(85, 170)
player4dealtCardsFrameSplitH1.player4H1CardImage5:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 378, -7)
player4dealtCardsFrameSplitH1.player4H1CardImage5:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH1.player4H1CardImage5:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH1.player4H1CardImage6 = player4dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH1.player4H1CardImage6:SetSize(85, 170)
player4dealtCardsFrameSplitH1.player4H1CardImage6:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 470, -7)
player4dealtCardsFrameSplitH1.player4H1CardImage6:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH1.player4H1CardImage6:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH1.player4H1CardImage7 = player4dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH1.player4H1CardImage7:SetSize(85, 170)
player4dealtCardsFrameSplitH1.player4H1CardImage7:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 562, -7)
player4dealtCardsFrameSplitH1.player4H1CardImage7:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH1.player4H1CardImage7:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH1.playerFirstCardText = player4dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH1.playerFirstCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 23, -80)
player4dealtCardsFrameSplitH1.playerFirstCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH1.playerFirstCardText:SetText("1st Card")
player4dealtCardsFrameSplitH1.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH1.playerFirstCardText:Hide()

player4dealtCardsFrameSplitH1.playerSecondCardText = player4dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH1.playerSecondCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 112, -80)
player4dealtCardsFrameSplitH1.playerSecondCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH1.playerSecondCardText:SetText("2nd Card")
player4dealtCardsFrameSplitH1.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH1.playerSecondCardText:Hide()

player4dealtCardsFrameSplitH1.playerThirdCardText = player4dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH1.playerThirdCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 207, -80)
player4dealtCardsFrameSplitH1.playerThirdCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH1.playerThirdCardText:SetText("3rd Card")
player4dealtCardsFrameSplitH1.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH1.playerThirdCardText:Hide()

player4dealtCardsFrameSplitH1.playerFourthCardText = player4dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH1.playerFourthCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 299, -80)
player4dealtCardsFrameSplitH1.playerFourthCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH1.playerFourthCardText:SetText("4th Card")
player4dealtCardsFrameSplitH1.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH1.playerFourthCardText:Hide()

player4dealtCardsFrameSplitH1.playerFifthCardText = player4dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH1.playerFifthCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 392, -80)
player4dealtCardsFrameSplitH1.playerFifthCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH1.playerFifthCardText:SetText("5th Card")
player4dealtCardsFrameSplitH1.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH1.playerFifthCardText:Hide()

player4dealtCardsFrameSplitH1.playerSixthCardText = player4dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH1.playerSixthCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 483, -80)
player4dealtCardsFrameSplitH1.playerSixthCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH1.playerSixthCardText:SetText("6th Card")
player4dealtCardsFrameSplitH1.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH1.playerSixthCardText:Hide()

player4dealtCardsFrameSplitH1.playerSeventhCardText = player4dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH1.playerSeventhCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH1, 576, -80)
player4dealtCardsFrameSplitH1.playerSeventhCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH1.playerSeventhCardText:SetText("7th Card")
player4dealtCardsFrameSplitH1.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH1.playerSeventhCardText:Hide()

-- Player H2 Dealt Cards Frame
player4dealtCardsFrameSplitH2= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player4dealtCardsFrameSplitH2:SetSize(656, 200)
player4dealtCardsFrameSplitH2:SetPoint("BOTTOM", playerFrame, 0, 5)
player4dealtCardsFrameSplitH2:SetFrameStrata("HIGH")
player4dealtCardsFrameSplitH2:SetFrameLevel(5)
player4dealtCardsFrameSplitH2:Hide()

-- "Hand 1" button which displays Player's Hand 1 cards
player4dealtCardsFrameSplitH2.playerH1CardsButton = CreateFrame("Button", nil, player4dealtCardsFrameSplitH2, "GameMenuButtonTemplate")
player4dealtCardsFrameSplitH2.playerH1CardsButton:SetPoint("TOPLEFT", player4dealtCardsFrameSplitH2, 8, -8)
player4dealtCardsFrameSplitH2.playerH1CardsButton:SetSize(75, 25)
player4dealtCardsFrameSplitH2.playerH1CardsButton:SetText("Hand 1")
player4dealtCardsFrameSplitH2.playerH1CardsButton:Hide()

-- "Hand 2" button which displays Player's Hand 2 cards
player4dealtCardsFrameSplitH2.playerH2CardsButton = CreateFrame("Button", nil, player4dealtCardsFrameSplitH2, "GameMenuButtonTemplate")
player4dealtCardsFrameSplitH2.playerH2CardsButton:SetPoint("TOPLEFT", player4dealtCardsFrameSplitH2, 84, -8)
player4dealtCardsFrameSplitH2.playerH2CardsButton:SetSize(75, 25)
player4dealtCardsFrameSplitH2.playerH2CardsButton:SetText("Hand 2")
player4dealtCardsFrameSplitH2.playerH2CardsButton:Disable()
player4dealtCardsFrameSplitH2.playerH2CardsButton:Hide()

player4dealtCardsFrameSplitH2.player4H2CardImage1 = player4dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH2.player4H2CardImage1:SetSize(85, 170)
player4dealtCardsFrameSplitH2.player4H2CardImage1:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 10, -7)
player4dealtCardsFrameSplitH2.player4H2CardImage1:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH2.player4H2CardImage1:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH2.player4H2CardImage2 = player4dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH2.player4H2CardImage2:SetSize(85, 170)
player4dealtCardsFrameSplitH2.player4H2CardImage2:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 102, -7)
player4dealtCardsFrameSplitH2.player4H2CardImage2:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH2.player4H2CardImage2:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH2.player4H2CardImage3 = player4dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH2.player4H2CardImage3:SetSize(85, 170)
player4dealtCardsFrameSplitH2.player4H2CardImage3:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 194, -7)
player4dealtCardsFrameSplitH2.player4H2CardImage3:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH2.player4H2CardImage3:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH2.player4H2CardImage4 = player4dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH2.player4H2CardImage4:SetSize(85, 170)
player4dealtCardsFrameSplitH2.player4H2CardImage4:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 286, -7)
player4dealtCardsFrameSplitH2.player4H2CardImage4:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH2.player4H2CardImage4:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH2.player4H2CardImage5 = player4dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH2.player4H2CardImage5:SetSize(85, 170)
player4dealtCardsFrameSplitH2.player4H2CardImage5:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 378, -7)
player4dealtCardsFrameSplitH2.player4H2CardImage5:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH2.player4H2CardImage5:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH2.player4H2CardImage6 = player4dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH2.player4H2CardImage6:SetSize(85, 170)
player4dealtCardsFrameSplitH2.player4H2CardImage6:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 470, -7)
player4dealtCardsFrameSplitH2.player4H2CardImage6:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH2.player4H2CardImage6:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH2.player4H2CardImage7 = player4dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player4dealtCardsFrameSplitH2.player4H2CardImage7:SetSize(85, 170)
player4dealtCardsFrameSplitH2.player4H2CardImage7:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 562, -7)
player4dealtCardsFrameSplitH2.player4H2CardImage7:SetBlendMode("BLEND")
player4dealtCardsFrameSplitH2.player4H2CardImage7:SetDrawLayer("ARTWORK")

player4dealtCardsFrameSplitH2.playerFirstCardText = player4dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH2.playerFirstCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 23, -80)
player4dealtCardsFrameSplitH2.playerFirstCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH2.playerFirstCardText:SetText("1st Card")
player4dealtCardsFrameSplitH2.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH2.playerFirstCardText:Hide()

player4dealtCardsFrameSplitH2.playerSecondCardText = player4dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH2.playerSecondCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 112, -80)
player4dealtCardsFrameSplitH2.playerSecondCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH2.playerSecondCardText:SetText("2nd Card")
player4dealtCardsFrameSplitH2.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH2.playerSecondCardText:Hide()

player4dealtCardsFrameSplitH2.playerThirdCardText = player4dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH2.playerThirdCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 207, -80)
player4dealtCardsFrameSplitH2.playerThirdCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH2.playerThirdCardText:SetText("3rd Card")
player4dealtCardsFrameSplitH2.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH2.playerThirdCardText:Hide()

player4dealtCardsFrameSplitH2.playerFourthCardText = player4dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH2.playerFourthCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 299, -80)
player4dealtCardsFrameSplitH2.playerFourthCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH2.playerFourthCardText:SetText("4th Card")
player4dealtCardsFrameSplitH2.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH2.playerFourthCardText:Hide()

player4dealtCardsFrameSplitH2.playerFifthCardText = player4dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH2.playerFifthCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 392, -80)
player4dealtCardsFrameSplitH2.playerFifthCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH2.playerFifthCardText:SetText("5th Card")
player4dealtCardsFrameSplitH2.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH2.playerFifthCardText:Hide()

player4dealtCardsFrameSplitH2.playerSixthCardText = player4dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH2.playerSixthCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 483, -80)
player4dealtCardsFrameSplitH2.playerSixthCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH2.playerSixthCardText:SetText("6th Card")
player4dealtCardsFrameSplitH2.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH2.playerSixthCardText:Hide()

player4dealtCardsFrameSplitH2.playerSeventhCardText = player4dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4dealtCardsFrameSplitH2.playerSeventhCardText:SetPoint("LEFT", player4dealtCardsFrameSplitH2, 576, -80)
player4dealtCardsFrameSplitH2.playerSeventhCardText:SetJustifyH("CENTER")
player4dealtCardsFrameSplitH2.playerSeventhCardText:SetText("7th Card")
player4dealtCardsFrameSplitH2.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4dealtCardsFrameSplitH2.playerSeventhCardText:Hide()






-- >> PLAYER 5 <<
-- >> PLAYER 5 <<
-- >> PLAYER 5 <<

-- Player Dealt Cards Frame
player5dealtCardsFrame= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player5dealtCardsFrame:SetSize(656, 200)
player5dealtCardsFrame:SetPoint("BOTTOM", playerFrame, 0, 5)
player5dealtCardsFrame:SetFrameStrata("HIGH")
player5dealtCardsFrame:SetFrameLevel(6)
player5dealtCardsFrame:Hide()

-- "Player" button which displays Player's Main Hand cards
player5dealtCardsFrame.playerCardsButton = CreateFrame("Button", nil, player5dealtCardsFrame, "GameMenuButtonTemplate")
player5dealtCardsFrame.playerCardsButton:SetPoint("TOPLEFT", player5dealtCardsFrame, 8, -8)
player5dealtCardsFrame.playerCardsButton:SetSize(75, 25)
player5dealtCardsFrame.playerCardsButton:SetText("Player")
player5dealtCardsFrame.playerCardsButton:Disable()
player5dealtCardsFrame.playerCardsButton:Hide()

player5dealtCardsFrame.notStartedYetText = player5dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrame.notStartedYetText:SetPoint("CENTER", player5dealtCardsFrame, 0, 0)
player5dealtCardsFrame.notStartedYetText:SetJustifyH("CENTER")
player5dealtCardsFrame.notStartedYetText:SetText("The round hasn't started yet")
player5dealtCardsFrame.notStartedYetText:SetFont("Fonts\\FRIZQT__.TTF", 20, "OUTLINE")
player5dealtCardsFrame.notStartedYetText:Hide()

player5dealtCardsFrame.player5MainCardImage1 = player5dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrame.player5MainCardImage1:SetSize(85, 170)
player5dealtCardsFrame.player5MainCardImage1:SetPoint("LEFT", player5dealtCardsFrame, 10, -7)
player5dealtCardsFrame.player5MainCardImage1:SetBlendMode("BLEND")
player5dealtCardsFrame.player5MainCardImage1:SetDrawLayer("ARTWORK")

player5dealtCardsFrame.player5MainCardImage2 = player5dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrame.player5MainCardImage2:SetSize(85, 170)
player5dealtCardsFrame.player5MainCardImage2:SetPoint("LEFT", player5dealtCardsFrame, 102, -7)
player5dealtCardsFrame.player5MainCardImage2:SetBlendMode("BLEND")
player5dealtCardsFrame.player5MainCardImage2:SetDrawLayer("ARTWORK")

player5dealtCardsFrame.player5MainCardImage3 = player5dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrame.player5MainCardImage3:SetSize(85, 170)
player5dealtCardsFrame.player5MainCardImage3:SetPoint("LEFT", player5dealtCardsFrame, 194, -7)
player5dealtCardsFrame.player5MainCardImage3:SetBlendMode("BLEND")
player5dealtCardsFrame.player5MainCardImage3:SetDrawLayer("ARTWORK")

player5dealtCardsFrame.player5MainCardImage4 = player5dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrame.player5MainCardImage4:SetSize(85, 170)
player5dealtCardsFrame.player5MainCardImage4:SetPoint("LEFT", player5dealtCardsFrame, 286, -7)
player5dealtCardsFrame.player5MainCardImage4:SetBlendMode("BLEND")
player5dealtCardsFrame.player5MainCardImage4:SetDrawLayer("ARTWORK")

player5dealtCardsFrame.player5MainCardImage5 = player5dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrame.player5MainCardImage5:SetSize(85, 170)
player5dealtCardsFrame.player5MainCardImage5:SetPoint("LEFT", player5dealtCardsFrame, 378, -7)
player5dealtCardsFrame.player5MainCardImage5:SetBlendMode("BLEND")
player5dealtCardsFrame.player5MainCardImage5:SetDrawLayer("ARTWORK")

player5dealtCardsFrame.player5MainCardImage6 = player5dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrame.player5MainCardImage6:SetSize(85, 170)
player5dealtCardsFrame.player5MainCardImage6:SetPoint("LEFT", player5dealtCardsFrame, 470, -7)
player5dealtCardsFrame.player5MainCardImage6:SetBlendMode("BLEND")
player5dealtCardsFrame.player5MainCardImage6:SetDrawLayer("ARTWORK")

player5dealtCardsFrame.player5MainCardImage7 = player5dealtCardsFrame:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrame.player5MainCardImage7:SetSize(85, 170)
player5dealtCardsFrame.player5MainCardImage7:SetPoint("LEFT", player5dealtCardsFrame, 562, -7)
player5dealtCardsFrame.player5MainCardImage7:SetBlendMode("BLEND")
player5dealtCardsFrame.player5MainCardImage7:SetDrawLayer("ARTWORK")

player5dealtCardsFrame.playerFirstCardText = player5dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrame.playerFirstCardText:SetPoint("LEFT", player5dealtCardsFrame, 23, -80)
player5dealtCardsFrame.playerFirstCardText:SetJustifyH("CENTER")
player5dealtCardsFrame.playerFirstCardText:SetText("1st Card")
player5dealtCardsFrame.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrame.playerFirstCardText:Hide()

player5dealtCardsFrame.playerSecondCardText = player5dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrame.playerSecondCardText:SetPoint("LEFT", player5dealtCardsFrame, 112, -80)
player5dealtCardsFrame.playerSecondCardText:SetJustifyH("CENTER")
player5dealtCardsFrame.playerSecondCardText:SetText("2nd Card")
player5dealtCardsFrame.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrame.playerSecondCardText:Hide()

player5dealtCardsFrame.playerThirdCardText = player5dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrame.playerThirdCardText:SetPoint("LEFT", player5dealtCardsFrame, 207, -80)
player5dealtCardsFrame.playerThirdCardText:SetJustifyH("CENTER")
player5dealtCardsFrame.playerThirdCardText:SetText("3rd Card")
player5dealtCardsFrame.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrame.playerThirdCardText:Hide()

player5dealtCardsFrame.playerFourthCardText = player5dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrame.playerFourthCardText:SetPoint("LEFT", player5dealtCardsFrame, 299, -80)
player5dealtCardsFrame.playerFourthCardText:SetJustifyH("CENTER")
player5dealtCardsFrame.playerFourthCardText:SetText("4th Card")
player5dealtCardsFrame.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrame.playerFourthCardText:Hide()

player5dealtCardsFrame.playerFifthCardText = player5dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrame.playerFifthCardText:SetPoint("LEFT", player5dealtCardsFrame, 392, -80)
player5dealtCardsFrame.playerFifthCardText:SetJustifyH("CENTER")
player5dealtCardsFrame.playerFifthCardText:SetText("5th Card")
player5dealtCardsFrame.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrame.playerFifthCardText:Hide()

player5dealtCardsFrame.playerSixthCardText = player5dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrame.playerSixthCardText:SetPoint("LEFT", player5dealtCardsFrame, 483, -80)
player5dealtCardsFrame.playerSixthCardText:SetJustifyH("CENTER")
player5dealtCardsFrame.playerSixthCardText:SetText("6th Card")
player5dealtCardsFrame.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrame.playerSixthCardText:Hide()

player5dealtCardsFrame.playerSeventhCardText = player5dealtCardsFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrame.playerSeventhCardText:SetPoint("LEFT", player5dealtCardsFrame, 576, -80)
player5dealtCardsFrame.playerSeventhCardText:SetJustifyH("CENTER")
player5dealtCardsFrame.playerSeventhCardText:SetText("7th Card")
player5dealtCardsFrame.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrame.playerSeventhCardText:Hide()

-- Player H1 Dealt Cards Frame
player5dealtCardsFrameSplitH1= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player5dealtCardsFrameSplitH1:SetSize(656, 200)
player5dealtCardsFrameSplitH1:SetPoint("BOTTOM", playerFrame, 0, 5)
player5dealtCardsFrameSplitH1:SetFrameStrata("HIGH")
player5dealtCardsFrameSplitH1:SetFrameLevel(5)
player5dealtCardsFrameSplitH1:Hide()

-- "Hand 1" button which displays Player's Hand 1 cards
player5dealtCardsFrameSplitH1.playerH1CardsButton = CreateFrame("Button", nil, player5dealtCardsFrameSplitH1, "GameMenuButtonTemplate")
player5dealtCardsFrameSplitH1.playerH1CardsButton:SetPoint("TOPLEFT", player5dealtCardsFrameSplitH1, 8, -8)
player5dealtCardsFrameSplitH1.playerH1CardsButton:SetSize(75, 25)
player5dealtCardsFrameSplitH1.playerH1CardsButton:SetText("Hand 1")
player5dealtCardsFrameSplitH1.playerH1CardsButton:Disable()
player5dealtCardsFrameSplitH1.playerH1CardsButton:Hide()

-- "Hand 2" button which displays Player's Hand 2 cards
player5dealtCardsFrameSplitH1.playerH2CardsButton = CreateFrame("Button", nil, player5dealtCardsFrameSplitH1, "GameMenuButtonTemplate")
player5dealtCardsFrameSplitH1.playerH2CardsButton:SetPoint("TOPLEFT", player5dealtCardsFrameSplitH1, 84, -8)
player5dealtCardsFrameSplitH1.playerH2CardsButton:SetSize(75, 25)
player5dealtCardsFrameSplitH1.playerH2CardsButton:SetText("Hand 2")
player5dealtCardsFrameSplitH1.playerH2CardsButton:Hide()

player5dealtCardsFrameSplitH1.player5H1CardImage1 = player5dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH1.player5H1CardImage1:SetSize(85, 170)
player5dealtCardsFrameSplitH1.player5H1CardImage1:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 10, -7)
player5dealtCardsFrameSplitH1.player5H1CardImage1:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH1.player5H1CardImage1:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH1.player5H1CardImage2 = player5dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH1.player5H1CardImage2:SetSize(85, 170)
player5dealtCardsFrameSplitH1.player5H1CardImage2:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 102, -7)
player5dealtCardsFrameSplitH1.player5H1CardImage2:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH1.player5H1CardImage2:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH1.player5H1CardImage3 = player5dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH1.player5H1CardImage3:SetSize(85, 170)
player5dealtCardsFrameSplitH1.player5H1CardImage3:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 194, -7)
player5dealtCardsFrameSplitH1.player5H1CardImage3:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH1.player5H1CardImage3:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH1.player5H1CardImage4 = player5dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH1.player5H1CardImage4:SetSize(85, 170)
player5dealtCardsFrameSplitH1.player5H1CardImage4:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 286, -7)
player5dealtCardsFrameSplitH1.player5H1CardImage4:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH1.player5H1CardImage4:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH1.player5H1CardImage5 = player5dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH1.player5H1CardImage5:SetSize(85, 170)
player5dealtCardsFrameSplitH1.player5H1CardImage5:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 378, -7)
player5dealtCardsFrameSplitH1.player5H1CardImage5:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH1.player5H1CardImage5:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH1.player5H1CardImage6 = player5dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH1.player5H1CardImage6:SetSize(85, 170)
player5dealtCardsFrameSplitH1.player5H1CardImage6:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 470, -7)
player5dealtCardsFrameSplitH1.player5H1CardImage6:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH1.player5H1CardImage6:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH1.player5H1CardImage7 = player5dealtCardsFrameSplitH1:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH1.player5H1CardImage7:SetSize(85, 170)
player5dealtCardsFrameSplitH1.player5H1CardImage7:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 562, -7)
player5dealtCardsFrameSplitH1.player5H1CardImage7:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH1.player5H1CardImage7:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH1.playerFirstCardText = player5dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH1.playerFirstCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 23, -80)
player5dealtCardsFrameSplitH1.playerFirstCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH1.playerFirstCardText:SetText("1st Card")
player5dealtCardsFrameSplitH1.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH1.playerFirstCardText:Hide()

player5dealtCardsFrameSplitH1.playerSecondCardText = player5dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH1.playerSecondCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 112, -80)
player5dealtCardsFrameSplitH1.playerSecondCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH1.playerSecondCardText:SetText("2nd Card")
player5dealtCardsFrameSplitH1.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH1.playerSecondCardText:Hide()

player5dealtCardsFrameSplitH1.playerThirdCardText = player5dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH1.playerThirdCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 207, -80)
player5dealtCardsFrameSplitH1.playerThirdCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH1.playerThirdCardText:SetText("3rd Card")
player5dealtCardsFrameSplitH1.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH1.playerThirdCardText:Hide()

player5dealtCardsFrameSplitH1.playerFourthCardText = player5dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH1.playerFourthCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 299, -80)
player5dealtCardsFrameSplitH1.playerFourthCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH1.playerFourthCardText:SetText("4th Card")
player5dealtCardsFrameSplitH1.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH1.playerFourthCardText:Hide()

player5dealtCardsFrameSplitH1.playerFifthCardText = player5dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH1.playerFifthCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 392, -80)
player5dealtCardsFrameSplitH1.playerFifthCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH1.playerFifthCardText:SetText("5th Card")
player5dealtCardsFrameSplitH1.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH1.playerFifthCardText:Hide()

player5dealtCardsFrameSplitH1.playerSixthCardText = player5dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH1.playerSixthCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 483, -80)
player5dealtCardsFrameSplitH1.playerSixthCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH1.playerSixthCardText:SetText("6th Card")
player5dealtCardsFrameSplitH1.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH1.playerSixthCardText:Hide()

player5dealtCardsFrameSplitH1.playerSeventhCardText = player5dealtCardsFrameSplitH1:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH1.playerSeventhCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH1, 576, -80)
player5dealtCardsFrameSplitH1.playerSeventhCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH1.playerSeventhCardText:SetText("7th Card")
player5dealtCardsFrameSplitH1.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH1.playerSeventhCardText:Hide()

-- Player H2 Dealt Cards Frame
player5dealtCardsFrameSplitH2= CreateFrame("Frame", "BlackjackDealtCardsFrame", UIParent, "InsetFrameTemplate")
player5dealtCardsFrameSplitH2:SetSize(656, 200)
player5dealtCardsFrameSplitH2:SetPoint("BOTTOM", playerFrame, 0, 5)
player5dealtCardsFrameSplitH2:SetFrameStrata("HIGH")
player5dealtCardsFrameSplitH2:SetFrameLevel(5)
player5dealtCardsFrameSplitH2:Hide()

-- "Hand 1" button which displays Player's Hand 1 cards
player5dealtCardsFrameSplitH2.playerH1CardsButton = CreateFrame("Button", nil, player5dealtCardsFrameSplitH2, "GameMenuButtonTemplate")
player5dealtCardsFrameSplitH2.playerH1CardsButton:SetPoint("TOPLEFT", player5dealtCardsFrameSplitH2, 8, -8)
player5dealtCardsFrameSplitH2.playerH1CardsButton:SetSize(75, 25)
player5dealtCardsFrameSplitH2.playerH1CardsButton:SetText("Hand 1")
player5dealtCardsFrameSplitH2.playerH1CardsButton:Hide()

-- "Hand 2" button which displays Player's Hand 2 cards
player5dealtCardsFrameSplitH2.playerH2CardsButton = CreateFrame("Button", nil, player5dealtCardsFrameSplitH2, "GameMenuButtonTemplate")
player5dealtCardsFrameSplitH2.playerH2CardsButton:SetPoint("TOPLEFT", player5dealtCardsFrameSplitH2, 84, -8)
player5dealtCardsFrameSplitH2.playerH2CardsButton:SetSize(75, 25)
player5dealtCardsFrameSplitH2.playerH2CardsButton:SetText("Hand 2")
player5dealtCardsFrameSplitH2.playerH2CardsButton:Disable()
player5dealtCardsFrameSplitH2.playerH2CardsButton:Hide()

player5dealtCardsFrameSplitH2.player5H2CardImage1 = player5dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH2.player5H2CardImage1:SetSize(85, 170)
player5dealtCardsFrameSplitH2.player5H2CardImage1:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 10, -7)
player5dealtCardsFrameSplitH2.player5H2CardImage1:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH2.player5H2CardImage1:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH2.player5H2CardImage2 = player5dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH2.player5H2CardImage2:SetSize(85, 170)
player5dealtCardsFrameSplitH2.player5H2CardImage2:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 102, -7)
player5dealtCardsFrameSplitH2.player5H2CardImage2:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH2.player5H2CardImage2:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH2.player5H2CardImage3 = player5dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH2.player5H2CardImage3:SetSize(85, 170)
player5dealtCardsFrameSplitH2.player5H2CardImage3:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 194, -7)
player5dealtCardsFrameSplitH2.player5H2CardImage3:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH2.player5H2CardImage3:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH2.player5H2CardImage4 = player5dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH2.player5H2CardImage4:SetSize(85, 170)
player5dealtCardsFrameSplitH2.player5H2CardImage4:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 286, -7)
player5dealtCardsFrameSplitH2.player5H2CardImage4:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH2.player5H2CardImage4:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH2.player5H2CardImage5 = player5dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH2.player5H2CardImage5:SetSize(85, 170)
player5dealtCardsFrameSplitH2.player5H2CardImage5:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 378, -7)
player5dealtCardsFrameSplitH2.player5H2CardImage5:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH2.player5H2CardImage5:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH2.player5H2CardImage6 = player5dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH2.player5H2CardImage6:SetSize(85, 170)
player5dealtCardsFrameSplitH2.player5H2CardImage6:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 470, -7)
player5dealtCardsFrameSplitH2.player5H2CardImage6:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH2.player5H2CardImage6:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH2.player5H2CardImage7 = player5dealtCardsFrameSplitH2:CreateTexture(nil, "OVERLAY")
player5dealtCardsFrameSplitH2.player5H2CardImage7:SetSize(85, 170)
player5dealtCardsFrameSplitH2.player5H2CardImage7:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 562, -7)
player5dealtCardsFrameSplitH2.player5H2CardImage7:SetBlendMode("BLEND")
player5dealtCardsFrameSplitH2.player5H2CardImage7:SetDrawLayer("ARTWORK")

player5dealtCardsFrameSplitH2.playerFirstCardText = player5dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH2.playerFirstCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 23, -80)
player5dealtCardsFrameSplitH2.playerFirstCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH2.playerFirstCardText:SetText("1st Card")
player5dealtCardsFrameSplitH2.playerFirstCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH2.playerFirstCardText:Hide()

player5dealtCardsFrameSplitH2.playerSecondCardText = player5dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH2.playerSecondCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 112, -80)
player5dealtCardsFrameSplitH2.playerSecondCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH2.playerSecondCardText:SetText("2nd Card")
player5dealtCardsFrameSplitH2.playerSecondCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH2.playerSecondCardText:Hide()

player5dealtCardsFrameSplitH2.playerThirdCardText = player5dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH2.playerThirdCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 207, -80)
player5dealtCardsFrameSplitH2.playerThirdCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH2.playerThirdCardText:SetText("3rd Card")
player5dealtCardsFrameSplitH2.playerThirdCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH2.playerThirdCardText:Hide()

player5dealtCardsFrameSplitH2.playerFourthCardText = player5dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH2.playerFourthCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 299, -80)
player5dealtCardsFrameSplitH2.playerFourthCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH2.playerFourthCardText:SetText("4th Card")
player5dealtCardsFrameSplitH2.playerFourthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH2.playerFourthCardText:Hide()

player5dealtCardsFrameSplitH2.playerFifthCardText = player5dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH2.playerFifthCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 392, -80)
player5dealtCardsFrameSplitH2.playerFifthCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH2.playerFifthCardText:SetText("5th Card")
player5dealtCardsFrameSplitH2.playerFifthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH2.playerFifthCardText:Hide()

player5dealtCardsFrameSplitH2.playerSixthCardText = player5dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH2.playerSixthCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 483, -80)
player5dealtCardsFrameSplitH2.playerSixthCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH2.playerSixthCardText:SetText("6th Card")
player5dealtCardsFrameSplitH2.playerSixthCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH2.playerSixthCardText:Hide()

player5dealtCardsFrameSplitH2.playerSeventhCardText = player5dealtCardsFrameSplitH2:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5dealtCardsFrameSplitH2.playerSeventhCardText:SetPoint("LEFT", player5dealtCardsFrameSplitH2, 576, -80)
player5dealtCardsFrameSplitH2.playerSeventhCardText:SetJustifyH("CENTER")
player5dealtCardsFrameSplitH2.playerSeventhCardText:SetText("7th Card")
player5dealtCardsFrameSplitH2.playerSeventhCardText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5dealtCardsFrameSplitH2.playerSeventhCardText:Hide()

















-- >> CHAT WINDOW <<
-- >> CHAT WINDOW <<
-- >> CHAT WINDOW <<

chatWindowHeight = 180
totalHeight = 168
lineHeight = 10

-- Create the chat window frame
chatWindowFrame = CreateFrame("Frame", "BlackjackChatWindowFrame", UIParent, "InsetFrameTemplate")
chatWindowFrame:SetSize(306, 200)
chatWindowFrame:SetPoint("BOTTOMRIGHT", playerFrame, -5, 5)
chatWindowFrame:SetFrameStrata("TOOLTIP")
chatWindowFrame:Hide()

-- Setting a title
chatWindowFrame.title = chatWindowFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
chatWindowFrame.title:SetPoint("TOP", chatWindowFrame, 0, -7)
chatWindowFrame.title:SetText("Chat Log")

-- Create the scroll frame
chatWindowFrame.ScrollFrame = CreateFrame("ScrollFrame", nil, chatWindowFrame, "UIPanelScrollFrameTemplate")
chatWindowFrame.ScrollFrame:SetPoint("TOPLEFT", chatWindowFrame, "TOPLEFT", 10, -27)
chatWindowFrame.ScrollFrame:SetPoint("BOTTOMRIGHT", chatWindowFrame, "BOTTOMRIGHT", -10, 9)
chatWindowFrame.ScrollFrame:SetClipsChildren(true)

-- Create the child frame for scrolling content
child = CreateFrame("Frame", nil, chatWindowFrame.ScrollFrame)
child:SetSize(288, chatWindowHeight)

child.bg = child:CreateTexture(nil, "BACKGROUND")
child.bg:SetAllPoints(true)

function AddMessageToScrollFrame(message, sender)
    -- Create a new font string for the message
    newMessage = child:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
    newMessage:SetJustifyH("LEFT")
    
    -- Check the sender and set text color accordingly
    local textColor
    if sender == characterName then
        textColor = {0.961, 0.294, 0.271}
    elseif string.find(message, "rolls") then
        textColor = {0.969, 0.969, 0.451}  -- Yellow color for /roll command
    else
        textColor = {0.961, 0.451, 0.208}  -- Default color for other senders
    end

    newMessage:SetTextColor(unpack(textColor))

    -- Replace specific tags with ">>"
    replacements = {
        ["{square}"] = ">>",
        ["{star}"] = ">>",
        ["{cross}"] = ">>",
        ["{triangle}"] = ">>",
        ["{skull}"] = ">>",
        ["{circle}"] = ">>",
        ["{diamond}"] = ">>",
        ["{moon}"] = ">>",
    }

    for tag, replacement in pairs(replacements) do
        message = string.gsub(message, tag, replacement)
    end

    newMessage:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

    -- Calculate the maximum width for a line
    maxWidth = child:GetWidth() - 16  -- Adjusted for left margin (8) and right margin (8)

    -- Split the message into words
    words = {strsplit(" ", message)}
    lines = {""}
    currentLine = 1

    for i, word in ipairs(words) do
        -- Check if adding the word exceeds the maximum width
        testString = lines[currentLine] == "" and word or lines[currentLine] .. " " .. word
        newMessage:SetText(testString)
        if newMessage:GetWidth() <= maxWidth then
            -- If the word fits, add it to the current line
            lines[currentLine] = testString
        else
            -- If the word exceeds the width, start a new line
            currentLine = currentLine + 1
            lines[currentLine] = word
        end
    end

    -- Position the new message below the previous messages
    for i, line in ipairs(lines) do
        formattedLine = line

        -- Skip adding "•" for continuation lines
        if i == 1 then
            if string.find(line, ">>") then
                formattedLine = line:gsub("•", "")
            else
                formattedLine = "• " .. line
            end
        end

        newMessage:SetText(formattedLine)
        newMessage:SetPoint("TOPLEFT", 0, -totalHeight)

        -- Update the total height with the height of the new message and spacing
        totalHeight = totalHeight + newMessage:GetHeight() + 1

        -- Set the height of the scroll child
        child:SetHeight(totalHeight)

        -- Calculate the maximum scroll range
        maxScroll = totalHeight - chatWindowHeight - 10
        maxScroll = math.max(0, maxScroll)  -- Ensure maxScroll is not negative

        -- Set the scroll frame scroll range to the total height
        chatWindowFrame.ScrollFrame:SetVerticalScroll(maxScroll)

        -- Create a new font string for the next line
        newMessage = child:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
        newMessage:SetJustifyH("LEFT")
        newMessage:SetTextColor(unpack(textColor))
        newMessage:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
    end

    -- Always scroll to the bottom to show the latest messages
    chatWindowFrame.ScrollFrame:UpdateScrollChildRect()

    newValue = chatWindowFrame.ScrollFrame:GetVerticalScrollRange()
    chatWindowFrame.ScrollFrame:SetVerticalScroll(newValue)
end

-- Set the child frame as the scroll child
chatWindowFrame.ScrollFrame:SetScrollChild(child)

chatWindowFrame.ScrollFrame:SetScript("OnMouseWheel", function(self, delta)
    scrollValue = self:GetVerticalScroll()
    newValue = scrollValue - (delta * lineHeight)

    if (newValue < 0) then
        newValue = 0
    elseif (newValue > self:GetVerticalScrollRange()) then
        newValue = self:GetVerticalScrollRange()
    end

    self:SetVerticalScroll(newValue)
end)





















-- >> SIDEBET NOTIFICATION WINDOWS <<
-- >> SIDEBET NOTIFICATION WINDOWS <<
-- >> SIDEBET NOTIFICATION WINDOWS <<

-- Creating the PP sideBetWinFrame
sideBetWinFramePP = CreateFrame("Frame", "BlackjackPayoutsFrame", UIParent, "BasicFrameTemplateWithInset")
sideBetWinFramePP:SetSize(325, 180)
sideBetWinFramePP:SetPoint("TOPLEFT", playerFrame, 0, 0)
sideBetWinFramePP:SetFrameStrata("TOOLTIP")
sideBetWinFramePP:Hide()

-- Setting a title
sideBetWinFramePP.title = sideBetWinFramePP:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFramePP.title:SetPoint("TOP", sideBetWinFramePP, 0, -5)
sideBetWinFramePP.title:SetText("Side Bet Notification")
sideBetWinFramePP.title:Hide()

sideBetWinFramePP.PPtext = sideBetWinFramePP:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFramePP.PPtext:SetPoint("TOPLEFT", sideBetWinFramePP, 5, -5)
sideBetWinFramePP.PPtext:SetJustifyH("CENTER")
sideBetWinFramePP.PPtext:SetText("PP")
sideBetWinFramePP.PPtext:SetTextColor(1, 0.298, 0.298)
sideBetWinFramePP.PPtext:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
sideBetWinFramePP.PPtext:Hide()

sideBetWinFramePP.MixedPairText = sideBetWinFramePP:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFramePP.MixedPairText:SetPoint("TOP", sideBetWinFramePP, 0, -31)
sideBetWinFramePP.MixedPairText:SetJustifyH("CENTER")
sideBetWinFramePP.MixedPairText:SetText("You hit a Mixed Pair!\nPayout is " .. mixedPairPayoutValue ..":1")
sideBetWinFramePP.MixedPairText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
sideBetWinFramePP.MixedPairText:Hide()

sideBetWinFramePP.ColouredPairText = sideBetWinFramePP:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFramePP.ColouredPairText:SetPoint("TOP", sideBetWinFramePP, 0, -31)
sideBetWinFramePP.ColouredPairText:SetJustifyH("CENTER")
sideBetWinFramePP.ColouredPairText:SetText("You hit a Coloured Pair!\nPayout is " .. colouredPairPayoutValue ..":1")
sideBetWinFramePP.ColouredPairText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
sideBetWinFramePP.ColouredPairText:Hide()

sideBetWinFramePP.PerfectPairText = sideBetWinFramePP:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFramePP.PerfectPairText:SetPoint("TOP", sideBetWinFramePP, 0, -31)
sideBetWinFramePP.PerfectPairText:SetJustifyH("CENTER")
sideBetWinFramePP.PerfectPairText:SetText("You hit a Perfect Pair!\nPayout is " .. perfectPairPayoutValue ..":1")
sideBetWinFramePP.PerfectPairText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
sideBetWinFramePP.PerfectPairText:Hide()

sideBetWinFramePP.player1PPCardImage1 = sideBetWinFramePP:CreateTexture(nil, "OVERLAY")
sideBetWinFramePP.player1PPCardImage1:SetSize(72, 144)
sideBetWinFramePP.player1PPCardImage1:SetPoint("CENTER", sideBetWinFramePP, -40, -23)
sideBetWinFramePP.player1PPCardImage1:SetBlendMode("BLEND")
sideBetWinFramePP.player1PPCardImage1:SetDrawLayer("ARTWORK")
sideBetWinFramePP.player1PPCardImage1:Hide()

sideBetWinFramePP.player1PPCardImage2 = sideBetWinFramePP:CreateTexture(nil, "OVERLAY")
sideBetWinFramePP.player1PPCardImage2:SetSize(72, 144)
sideBetWinFramePP.player1PPCardImage2:SetPoint("CENTER", sideBetWinFramePP, 40, -23)
sideBetWinFramePP.player1PPCardImage2:SetBlendMode("BLEND")
sideBetWinFramePP.player1PPCardImage2:SetDrawLayer("ARTWORK")
sideBetWinFramePP.player1PPCardImage2:Hide()

sideBetWinFramePP.player2PPCardImage1 = sideBetWinFramePP:CreateTexture(nil, "OVERLAY")
sideBetWinFramePP.player2PPCardImage1:SetSize(72, 144)
sideBetWinFramePP.player2PPCardImage1:SetPoint("CENTER", sideBetWinFramePP, -40, -23)
sideBetWinFramePP.player2PPCardImage1:SetBlendMode("BLEND")
sideBetWinFramePP.player2PPCardImage1:SetDrawLayer("ARTWORK")
sideBetWinFramePP.player2PPCardImage1:Hide()

sideBetWinFramePP.player2PPCardImage2 = sideBetWinFramePP:CreateTexture(nil, "OVERLAY")
sideBetWinFramePP.player2PPCardImage2:SetSize(72, 144)
sideBetWinFramePP.player2PPCardImage2:SetPoint("CENTER", sideBetWinFramePP, 40, -23)
sideBetWinFramePP.player2PPCardImage2:SetBlendMode("BLEND")
sideBetWinFramePP.player2PPCardImage2:SetDrawLayer("ARTWORK")
sideBetWinFramePP.player2PPCardImage2:Hide()

sideBetWinFramePP.player3PPCardImage1 = sideBetWinFramePP:CreateTexture(nil, "OVERLAY")
sideBetWinFramePP.player3PPCardImage1:SetSize(72, 144)
sideBetWinFramePP.player3PPCardImage1:SetPoint("CENTER", sideBetWinFramePP, -40, -23)
sideBetWinFramePP.player3PPCardImage1:SetBlendMode("BLEND")
sideBetWinFramePP.player3PPCardImage1:SetDrawLayer("ARTWORK")
sideBetWinFramePP.player3PPCardImage1:Hide()

sideBetWinFramePP.player3PPCardImage2 = sideBetWinFramePP:CreateTexture(nil, "OVERLAY")
sideBetWinFramePP.player3PPCardImage2:SetSize(72, 144)
sideBetWinFramePP.player3PPCardImage2:SetPoint("CENTER", sideBetWinFramePP, 40, -23)
sideBetWinFramePP.player3PPCardImage2:SetBlendMode("BLEND")
sideBetWinFramePP.player3PPCardImage2:SetDrawLayer("ARTWORK")
sideBetWinFramePP.player3PPCardImage2:Hide()

sideBetWinFramePP.player4PPCardImage1 = sideBetWinFramePP:CreateTexture(nil, "OVERLAY")
sideBetWinFramePP.player4PPCardImage1:SetSize(72, 144)
sideBetWinFramePP.player4PPCardImage1:SetPoint("CENTER", sideBetWinFramePP, -40, -23)
sideBetWinFramePP.player4PPCardImage1:SetBlendMode("BLEND")
sideBetWinFramePP.player4PPCardImage1:SetDrawLayer("ARTWORK")
sideBetWinFramePP.player4PPCardImage1:Hide()

sideBetWinFramePP.player4PPCardImage2 = sideBetWinFramePP:CreateTexture(nil, "OVERLAY")
sideBetWinFramePP.player4PPCardImage2:SetSize(72, 144)
sideBetWinFramePP.player4PPCardImage2:SetPoint("CENTER", sideBetWinFramePP, 40, -23)
sideBetWinFramePP.player4PPCardImage2:SetBlendMode("BLEND")
sideBetWinFramePP.player4PPCardImage2:SetDrawLayer("ARTWORK")
sideBetWinFramePP.player4PPCardImage2:Hide()

sideBetWinFramePP.player5PPCardImage1 = sideBetWinFramePP:CreateTexture(nil, "OVERLAY")
sideBetWinFramePP.player5PPCardImage1:SetSize(72, 144)
sideBetWinFramePP.player5PPCardImage1:SetPoint("CENTER", sideBetWinFramePP, -40, -23)
sideBetWinFramePP.player5PPCardImage1:SetBlendMode("BLEND")
sideBetWinFramePP.player5PPCardImage1:SetDrawLayer("ARTWORK")
sideBetWinFramePP.player5PPCardImage1:Hide()

sideBetWinFramePP.player5PPCardImage2 = sideBetWinFramePP:CreateTexture(nil, "OVERLAY")
sideBetWinFramePP.player5PPCardImage2:SetSize(72, 144)
sideBetWinFramePP.player5PPCardImage2:SetPoint("CENTER", sideBetWinFramePP, 40, -23)
sideBetWinFramePP.player5PPCardImage2:SetBlendMode("BLEND")
sideBetWinFramePP.player5PPCardImage2:SetDrawLayer("ARTWORK")
sideBetWinFramePP.player5PPCardImage2:Hide()

-- Creating the 21+3 sideBetWinFrame
sideBetWinFrame213 = CreateFrame("Frame", "BlackjackPayoutsFrame", UIParent, "BasicFrameTemplateWithInset")
sideBetWinFrame213:SetSize(325, 180)
sideBetWinFrame213:SetPoint("TOPLEFT", playerFrame, 0, -180)
sideBetWinFrame213:SetFrameStrata("TOOLTIP")
sideBetWinFrame213:Hide()

-- Setting a title
sideBetWinFrame213.title = sideBetWinFrame213:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFrame213.title:SetPoint("TOP", sideBetWinFrame213, 0, -5)
sideBetWinFrame213.title:SetText("Side Bet Notification")
sideBetWinFrame213.title:Hide()

sideBetWinFrame213.t213text = sideBetWinFrame213:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFrame213.t213text:SetPoint("TOPLEFT", sideBetWinFrame213, 5, -5)
sideBetWinFrame213.t213text:SetJustifyH("CENTER")
sideBetWinFrame213.t213text:SetText("21+3")
sideBetWinFrame213.t213text:SetTextColor(1, 0.298, 0.298)
sideBetWinFrame213.t213text:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
sideBetWinFrame213.t213text:Hide()

sideBetWinFrame213.FlushText = sideBetWinFrame213:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFrame213.FlushText:SetPoint("TOP", sideBetWinFrame213, 0, -31)
sideBetWinFrame213.FlushText:SetJustifyH("CENTER")
sideBetWinFrame213.FlushText:SetText("You hit a Flush!\nPayout is " .. flushPayoutValue ..":1")
sideBetWinFrame213.FlushText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
sideBetWinFrame213.FlushText:Hide()

sideBetWinFrame213.StraightText = sideBetWinFrame213:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFrame213.StraightText:SetPoint("TOP", sideBetWinFrame213, 0, -31)
sideBetWinFrame213.StraightText:SetJustifyH("CENTER")
sideBetWinFrame213.StraightText:SetText("You hit a Straight!\nPayout is " .. straightPayoutValue ..":1")
sideBetWinFrame213.StraightText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
sideBetWinFrame213.StraightText:Hide()

sideBetWinFrame213.ThreeOfAKindText = sideBetWinFrame213:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFrame213.ThreeOfAKindText:SetPoint("TOP", sideBetWinFrame213, 0, -31)
sideBetWinFrame213.ThreeOfAKindText:SetJustifyH("CENTER")
sideBetWinFrame213.ThreeOfAKindText:SetText("You hit a Three of a Kind!\nPayout is " .. threeOfAKindPayoutValue ..":1")
sideBetWinFrame213.ThreeOfAKindText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
sideBetWinFrame213.ThreeOfAKindText:Hide()

sideBetWinFrame213.StraightFlushText = sideBetWinFrame213:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFrame213.StraightFlushText:SetPoint("TOP", sideBetWinFrame213, 0, -31)
sideBetWinFrame213.StraightFlushText:SetJustifyH("CENTER")
sideBetWinFrame213.StraightFlushText:SetText("You hit a Straight Flush!\nPayout is " .. straightFlushPayoutValue ..":1")
sideBetWinFrame213.StraightFlushText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
sideBetWinFrame213.StraightFlushText:Hide()

sideBetWinFrame213.SuitedThreeOfAKindText = sideBetWinFrame213:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
sideBetWinFrame213.SuitedThreeOfAKindText:SetPoint("TOP", sideBetWinFrame213, 0, -31)
sideBetWinFrame213.SuitedThreeOfAKindText:SetJustifyH("CENTER")
sideBetWinFrame213.SuitedThreeOfAKindText:SetText("You hit a Suited Three of a Kind!\nPayout is " .. suitedThreeOfAKindPayoutValue ..":1")
sideBetWinFrame213.SuitedThreeOfAKindText:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
sideBetWinFrame213.SuitedThreeOfAKindText:Hide()

sideBetWinFrame213.dealer213CardImage1 = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.dealer213CardImage1:SetSize(72, 144)
sideBetWinFrame213.dealer213CardImage1:SetPoint("CENTER", sideBetWinFrame213, 100, -23)
sideBetWinFrame213.dealer213CardImage1:SetBlendMode("BLEND")
sideBetWinFrame213.dealer213CardImage1:SetDrawLayer("ARTWORK")
sideBetWinFrame213.dealer213CardImage1:Hide()

sideBetWinFrame213.player1213CardImage1 = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.player1213CardImage1:SetSize(72, 144)
sideBetWinFrame213.player1213CardImage1:SetPoint("CENTER", sideBetWinFrame213, -100, -23)
sideBetWinFrame213.player1213CardImage1:SetBlendMode("BLEND")
sideBetWinFrame213.player1213CardImage1:SetDrawLayer("ARTWORK")
sideBetWinFrame213.player1213CardImage1:Hide()

sideBetWinFrame213.player1213CardImage2 = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.player1213CardImage2:SetSize(72, 144)
sideBetWinFrame213.player1213CardImage2:SetPoint("CENTER", sideBetWinFrame213, -20, -23)
sideBetWinFrame213.player1213CardImage2:SetBlendMode("BLEND")
sideBetWinFrame213.player1213CardImage2:SetDrawLayer("ARTWORK")
sideBetWinFrame213.player1213CardImage2:Hide()

sideBetWinFrame213.player2213CardImage1 = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.player2213CardImage1:SetSize(72, 144)
sideBetWinFrame213.player2213CardImage1:SetPoint("CENTER", sideBetWinFrame213, -100, -23)
sideBetWinFrame213.player2213CardImage1:SetBlendMode("BLEND")
sideBetWinFrame213.player2213CardImage1:SetDrawLayer("ARTWORK")
sideBetWinFrame213.player2213CardImage1:Hide()

sideBetWinFrame213.player2213CardImage2 = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.player2213CardImage2:SetSize(72, 144)
sideBetWinFrame213.player2213CardImage2:SetPoint("CENTER", sideBetWinFrame213, -20, -23)
sideBetWinFrame213.player2213CardImage2:SetBlendMode("BLEND")
sideBetWinFrame213.player2213CardImage2:SetDrawLayer("ARTWORK")
sideBetWinFrame213.player2213CardImage2:Hide()

sideBetWinFrame213.player3213CardImage1 = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.player3213CardImage1:SetSize(72, 144)
sideBetWinFrame213.player3213CardImage1:SetPoint("CENTER", sideBetWinFrame213, -100, -23)
sideBetWinFrame213.player3213CardImage1:SetBlendMode("BLEND")
sideBetWinFrame213.player3213CardImage1:SetDrawLayer("ARTWORK")
sideBetWinFrame213.player3213CardImage1:Hide()

sideBetWinFrame213.player3213CardImage2 = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.player3213CardImage2:SetSize(72, 144)
sideBetWinFrame213.player3213CardImage2:SetPoint("CENTER", sideBetWinFrame213, -20, -23)
sideBetWinFrame213.player3213CardImage2:SetBlendMode("BLEND")
sideBetWinFrame213.player3213CardImage2:SetDrawLayer("ARTWORK")
sideBetWinFrame213.player3213CardImage2:Hide()

sideBetWinFrame213.player4213CardImage1 = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.player4213CardImage1:SetSize(72, 144)
sideBetWinFrame213.player4213CardImage1:SetPoint("CENTER", sideBetWinFrame213, -100, -23)
sideBetWinFrame213.player4213CardImage1:SetBlendMode("BLEND")
sideBetWinFrame213.player4213CardImage1:SetDrawLayer("ARTWORK")
sideBetWinFrame213.player4213CardImage1:Hide()

sideBetWinFrame213.player4213CardImage2 = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.player4213CardImage2:SetSize(72, 144)
sideBetWinFrame213.player4213CardImage2:SetPoint("CENTER", sideBetWinFrame213, -20, -23)
sideBetWinFrame213.player4213CardImage2:SetBlendMode("BLEND")
sideBetWinFrame213.player4213CardImage2:SetDrawLayer("ARTWORK")
sideBetWinFrame213.player4213CardImage2:Hide()

sideBetWinFrame213.player5213CardImage1 = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.player5213CardImage1:SetSize(72, 144)
sideBetWinFrame213.player5213CardImage1:SetPoint("CENTER", sideBetWinFrame213, -100, -23)
sideBetWinFrame213.player5213CardImage1:SetBlendMode("BLEND")
sideBetWinFrame213.player5213CardImage1:SetDrawLayer("ARTWORK")
sideBetWinFrame213.player5213CardImage1:Hide()

sideBetWinFrame213.player5213CardImage2 = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.player5213CardImage2:SetSize(72, 144)
sideBetWinFrame213.player5213CardImage2:SetPoint("CENTER", sideBetWinFrame213, -20, -23)
sideBetWinFrame213.player5213CardImage2:SetBlendMode("BLEND")
sideBetWinFrame213.player5213CardImage2:SetDrawLayer("ARTWORK")
sideBetWinFrame213.player5213CardImage2:Hide()

sideBetWinFrame213.PlusSymbol = sideBetWinFrame213:CreateTexture(nil, "OVERLAY")
sideBetWinFrame213.PlusSymbol:SetSize(32, 32)
sideBetWinFrame213.PlusSymbol:SetPoint("CENTER", sideBetWinFrame213, 40, -23)
sideBetWinFrame213.PlusSymbol:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\PlusSymbol.tga")
sideBetWinFrame213.PlusSymbol:SetBlendMode("BLEND")
sideBetWinFrame213.PlusSymbol:SetDrawLayer("ARTWORK")
sideBetWinFrame213.PlusSymbol:Hide()

function player1MixedPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.MixedPairText:Show()
    sideBetWinFramePP.player1PPCardImage1:Show()
    sideBetWinFramePP.player1PPCardImage2:Show()
end
function player1ColouredPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.ColouredPairText:Show()
    sideBetWinFramePP.player1PPCardImage1:Show()
    sideBetWinFramePP.player1PPCardImage2:Show()
end
function player1PerfectPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.PerfectPairText:Show()
    sideBetWinFramePP.player1PPCardImage1:Show()
    sideBetWinFramePP.player1PPCardImage2:Show()
end
function player1SuitedThreeOfAKindNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.SuitedThreeOfAKindText:Show()
    sideBetWinFrame213.player1213CardImage1:Show()
    sideBetWinFrame213.player1213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player1StraightFlushNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.StraightFlushText:Show()
    sideBetWinFrame213.player1213CardImage1:Show()
    sideBetWinFrame213.player1213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player1ThreeOfAKindNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.ThreeOfAKindText:Show()
    sideBetWinFrame213.player1213CardImage1:Show()
    sideBetWinFrame213.player1213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player1StraightNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.StraightText:Show()
    sideBetWinFrame213.player1213CardImage1:Show()
    sideBetWinFrame213.player1213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player1FlushNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.FlushText:Show()
    sideBetWinFrame213.player1213CardImage1:Show()
    sideBetWinFrame213.player1213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end



function player2MixedPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.MixedPairText:Show()
    sideBetWinFramePP.player2PPCardImage1:Show()
    sideBetWinFramePP.player2PPCardImage2:Show()
end
function player2ColouredPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.ColouredPairText:Show()
    sideBetWinFramePP.player2PPCardImage1:Show()
    sideBetWinFramePP.player2PPCardImage2:Show()
end
function player2PerfectPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.PerfectPairText:Show()
    sideBetWinFramePP.player2PPCardImage1:Show()
    sideBetWinFramePP.player2PPCardImage2:Show()
end
function player2SuitedThreeOfAKindNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.SuitedThreeOfAKindText:Show()
    sideBetWinFrame213.player2213CardImage1:Show()
    sideBetWinFrame213.player2213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player2StraightFlushNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.StraightFlushText:Show()
    sideBetWinFrame213.player2213CardImage1:Show()
    sideBetWinFrame213.player2213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player2ThreeOfAKindNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.ThreeOfAKindText:Show()
    sideBetWinFrame213.player2213CardImage1:Show()
    sideBetWinFrame213.player2213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player2StraightNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.StraightText:Show()
    sideBetWinFrame213.player2213CardImage1:Show()
    sideBetWinFrame213.player2213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player2FlushNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.FlushText:Show()
    sideBetWinFrame213.player2213CardImage1:Show()
    sideBetWinFrame213.player2213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end



function player3MixedPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.MixedPairText:Show()
    sideBetWinFramePP.player3PPCardImage1:Show()
    sideBetWinFramePP.player3PPCardImage2:Show()
end
function player3ColouredPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.ColouredPairText:Show()
    sideBetWinFramePP.player3PPCardImage1:Show()
    sideBetWinFramePP.player3PPCardImage2:Show()
end
function player3PerfectPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.PerfectPairText:Show()
    sideBetWinFramePP.player3PPCardImage1:Show()
    sideBetWinFramePP.player3PPCardImage2:Show()
end
function player3SuitedThreeOfAKindNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.SuitedThreeOfAKindText:Show()
    sideBetWinFrame213.player3213CardImage1:Show()
    sideBetWinFrame213.player3213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player3StraightFlushNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.StraightFlushText:Show()
    sideBetWinFrame213.player3213CardImage1:Show()
    sideBetWinFrame213.player3213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player3ThreeOfAKindNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.ThreeOfAKindText:Show()
    sideBetWinFrame213.player3213CardImage1:Show()
    sideBetWinFrame213.player3213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player3StraightNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.StraightText:Show()
    sideBetWinFrame213.player3213CardImage1:Show()
    sideBetWinFrame213.player3213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player3FlushNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.FlushText:Show()
    sideBetWinFrame213.player3213CardImage1:Show()
    sideBetWinFrame213.player3213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end



function player4MixedPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.MixedPairText:Show()
    sideBetWinFramePP.player4PPCardImage1:Show()
    sideBetWinFramePP.player4PPCardImage2:Show()
end
function player4ColouredPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.ColouredPairText:Show()
    sideBetWinFramePP.player4PPCardImage1:Show()
    sideBetWinFramePP.player4PPCardImage2:Show()
end
function player4PerfectPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.PerfectPairText:Show()
    sideBetWinFramePP.player4PPCardImage1:Show()
    sideBetWinFramePP.player4PPCardImage2:Show()
end
function player4SuitedThreeOfAKindNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.SuitedThreeOfAKindText:Show()
    sideBetWinFrame213.player4213CardImage1:Show()
    sideBetWinFrame213.player4213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player4StraightFlushNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.StraightFlushText:Show()
    sideBetWinFrame213.player4213CardImage1:Show()
    sideBetWinFrame213.player4213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player4ThreeOfAKindNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.ThreeOfAKindText:Show()
    sideBetWinFrame213.player4213CardImage1:Show()
    sideBetWinFrame213.player4213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player4StraightNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.StraightText:Show()
    sideBetWinFrame213.player4213CardImage1:Show()
    sideBetWinFrame213.player4213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player4FlushNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.FlushText:Show()
    sideBetWinFrame213.player4213CardImage1:Show()
    sideBetWinFrame213.player4213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end



function player5MixedPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.MixedPairText:Show()
    sideBetWinFramePP.player5PPCardImage1:Show()
    sideBetWinFramePP.player5PPCardImage2:Show()
end
function player5ColouredPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.ColouredPairText:Show()
    sideBetWinFramePP.player5PPCardImage1:Show()
    sideBetWinFramePP.player5PPCardImage2:Show()
end
function player5PerfectPairNotification()
    sideBetWinFramePP:Show()
    sideBetWinFramePP.title:Show()
    sideBetWinFramePP.PPtext:Show()
    sideBetWinFramePP.PerfectPairText:Show()
    sideBetWinFramePP.player5PPCardImage1:Show()
    sideBetWinFramePP.player5PPCardImage2:Show()
end
function player5SuitedThreeOfAKindNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.SuitedThreeOfAKindText:Show()
    sideBetWinFrame213.player5213CardImage1:Show()
    sideBetWinFrame213.player5213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player5StraightFlushNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.StraightFlushText:Show()
    sideBetWinFrame213.player5213CardImage1:Show()
    sideBetWinFrame213.player5213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player5ThreeOfAKindNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.ThreeOfAKindText:Show()
    sideBetWinFrame213.player5213CardImage1:Show()
    sideBetWinFrame213.player5213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player5StraightNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.StraightText:Show()
    sideBetWinFrame213.player5213CardImage1:Show()
    sideBetWinFrame213.player5213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end
function player5FlushNotification()

    sideBetWinFrame213:Show()
    sideBetWinFrame213.title:Show()
    sideBetWinFrame213.t213text:Show()
    sideBetWinFrame213.FlushText:Show()
    sideBetWinFrame213.player5213CardImage1:Show()
    sideBetWinFrame213.player5213CardImage2:Show()
    sideBetWinFrame213.dealer213CardImage1:Show()
    sideBetWinFrame213.PlusSymbol:Show()

end










playerFrame:SetScript("OnHide", function(self)
    PlaySoundFile(soundFilePaths[117])
    bankrollFrame:Hide()
    preloadFrame:Hide()
    historyFrame:Hide()
    payoutsFrame:Hide()
    tableLimitsFrame:Hide()
    tableLimitsTitleFrame:Hide()
    tableLimitsTextFrame:Hide()
    sideBetWinFramePP:Hide()
    sideBetWinFrame213:Hide()
    player1dealtCardsFrame:Hide()
    player1dealtCardsFrameSplitH1:Hide()
    player1dealtCardsFrameSplitH2:Hide()
    player2dealtCardsFrame:Hide()
    player2dealtCardsFrameSplitH1:Hide()
    player2dealtCardsFrameSplitH2:Hide()
    player3dealtCardsFrame:Hide()
    player3dealtCardsFrameSplitH1:Hide()
    player3dealtCardsFrameSplitH2:Hide()
    player4dealtCardsFrame:Hide()
    player4dealtCardsFrameSplitH1:Hide()
    player4dealtCardsFrameSplitH2:Hide()
    player5dealtCardsFrame:Hide()
    player5dealtCardsFrameSplitH1:Hide()
    player5dealtCardsFrameSplitH2:Hide()
    chatWindowFrame:Hide()

    if playerName == unitName1 then
        playerFrame.leaveSeat1Button:Hide()
        playerFrame.player1HitButton:Hide()
        playerFrame.player1StandButton:Hide()
        playerFrame.player1DoubleButton:Hide()
        playerFrame.player1SplitButton:Hide()
        playerFrame.player1InsuranceYesButton:Hide()
        playerFrame.player1InsuranceNoButton:Hide()
        player1ConfirmMainBetButton:Hide()
        player1ConfirmPPBetButton:Hide()
        player1Confirm213BetButton:Hide()
        player1MainBetEditBox:Hide()
        player1PPBetEditBox:Hide()
        player1213BetEditBox:Hide()
        playerFrame.player1MainBetTitle:Hide()
        playerFrame.player1PPBetTitle:Hide()
        playerFrame.player1213BetTitle:Hide()
        playerFrame.player1InsuranceTitle:Hide()
        playerFrame.player1InsuranceSubtitle:Hide()
        menuFrame.cardsButton:Disable()
        playerFrame.historyButton:Disable()
        menuFrame.preloadButton:Disable()
        playerFrame.cashDeskButton:Disable()
        bankrollFrame.player1TotalBankrollTableDisplay:Hide()
        bankrollFrame.BaseTextDisplay:Show()
        cashDeskFrame.player1TotalBankroll:Hide()
        if gameRunning == false then
            playerFrame.player1Name:SetText("Seat Empty")
            SendChatMessage("{circle} " .. playerName .. " has left the table.", "RAID")
        else
            SendChatMessage("{skull} " .. playerName .. " exited the table before the round finished.", "RAID")
        end
        playerFrame.takeSeat1Button:Show()
        playerFrame.takeSeat1Button:Enable()
        if playerFrame.player2Name:GetText() == "Seat Empty" then    
            playerFrame.takeSeat2Button:Enable()
        end
        if playerFrame.player3Name:GetText() == "Seat Empty" then  
            playerFrame.takeSeat3Button:Enable()
        end
        if playerFrame.player4Name:GetText() == "Seat Empty" then 
            playerFrame.takeSeat4Button:Enable()
        end
        if playerFrame.player5Name:GetText() == "Seat Empty" then
            playerFrame.takeSeat5Button:Enable()
        end
    elseif playerName == unitName2 then
        playerFrame.leaveSeat2Button:Hide()
        playerFrame.player2HitButton:Hide()
        playerFrame.player2StandButton:Hide()
        playerFrame.player2DoubleButton:Hide()
        playerFrame.player2SplitButton:Hide()
        playerFrame.player2InsuranceYesButton:Hide()
        playerFrame.player2InsuranceNoButton:Hide()
        player2ConfirmMainBetButton:Hide()
        player2ConfirmPPBetButton:Hide()
        player2Confirm213BetButton:Hide()
        player2MainBetEditBox:Hide()
        player2PPBetEditBox:Hide()
        player2213BetEditBox:Hide()
        playerFrame.player2MainBetTitle:Hide()
        playerFrame.player2PPBetTitle:Hide()
        playerFrame.player2213BetTitle:Hide()
        playerFrame.player2InsuranceTitle:Hide()
        playerFrame.player2InsuranceSubtitle:Hide()
        menuFrame.cardsButton:Disable()
        playerFrame.historyButton:Disable()
        menuFrame.preloadButton:Disable()
        playerFrame.cashDeskButton:Disable()
        bankrollFrame.player2TotalBankrollTableDisplay:Hide()
        bankrollFrame.BaseTextDisplay:Show()
        cashDeskFrame.player2TotalBankroll:Hide()
        if gameRunning == false then
            playerFrame.player2Name:SetText("Seat Empty")
            SendChatMessage("{circle} " .. playerName .. " has left the table.", "RAID")
        else
            SendChatMessage("{skull} " .. playerName .. " exited the table before the round finished.", "RAID")
        end
        playerFrame.takeSeat2Button:Show()
        playerFrame.takeSeat2Button:Enable()
        if playerFrame.player1Name:GetText() == "Seat Empty" then    
            playerFrame.takeSeat1Button:Enable()
        end
        if playerFrame.player3Name:GetText() == "Seat Empty" then  
            playerFrame.takeSeat3Button:Enable()
        end
        if playerFrame.player4Name:GetText() == "Seat Empty" then 
            playerFrame.takeSeat4Button:Enable()
        end
        if playerFrame.player5Name:GetText() == "Seat Empty" then
            playerFrame.takeSeat5Button:Enable()
        end
    elseif playerName == unitName3 then
        playerFrame.leaveSeat3Button:Hide()
        playerFrame.player3HitButton:Hide()
        playerFrame.player3StandButton:Hide()
        playerFrame.player3DoubleButton:Hide()
        playerFrame.player3SplitButton:Hide()
        playerFrame.player3InsuranceYesButton:Hide()
        playerFrame.player3InsuranceNoButton:Hide()
        player3ConfirmMainBetButton:Hide()
        player3ConfirmPPBetButton:Hide()
        player3Confirm213BetButton:Hide()
        player3MainBetEditBox:Hide()
        player3PPBetEditBox:Hide()
        player3213BetEditBox:Hide()
        playerFrame.player3MainBetTitle:Hide()
        playerFrame.player3PPBetTitle:Hide()
        playerFrame.player3213BetTitle:Hide()
        playerFrame.player3InsuranceTitle:Hide()
        playerFrame.player3InsuranceSubtitle:Hide()
        menuFrame.cardsButton:Disable()
        playerFrame.historyButton:Disable()
        menuFrame.preloadButton:Disable()
        playerFrame.cashDeskButton:Disable()
        bankrollFrame.player3TotalBankrollTableDisplay:Hide()
        bankrollFrame.BaseTextDisplay:Show()
        cashDeskFrame.player3TotalBankroll:Hide()
        if gameRunning == false then
            playerFrame.player3Name:SetText("Seat Empty")
            SendChatMessage("{circle} " .. playerName .. " has left the table.", "RAID")
        else
            SendChatMessage("{skull} " .. playerName .. " exited the table before the round finished.", "RAID")
        end
        playerFrame.takeSeat3Button:Show()
        playerFrame.takeSeat3Button:Enable()
        if playerFrame.player1Name:GetText() == "Seat Empty" then    
            playerFrame.takeSeat1Button:Enable()
        end
        if playerFrame.player2Name:GetText() == "Seat Empty" then  
            playerFrame.takeSeat2Button:Enable()
        end
        if playerFrame.player4Name:GetText() == "Seat Empty" then 
            playerFrame.takeSeat4Button:Enable()
        end
        if playerFrame.player5Name:GetText() == "Seat Empty" then
            playerFrame.takeSeat5Button:Enable()
        end
    elseif playerName == unitName4 then
        playerFrame.leaveSeat4Button:Hide()
        playerFrame.player4HitButton:Hide()
        playerFrame.player4StandButton:Hide()
        playerFrame.player4DoubleButton:Hide()
        playerFrame.player4SplitButton:Hide()
        playerFrame.player4InsuranceYesButton:Hide()
        playerFrame.player4InsuranceNoButton:Hide()
        player4ConfirmMainBetButton:Hide()
        player4ConfirmPPBetButton:Hide()
        player4Confirm213BetButton:Hide()
        player4MainBetEditBox:Hide()
        player4PPBetEditBox:Hide()
        player4213BetEditBox:Hide()
        playerFrame.player4MainBetTitle:Hide()
        playerFrame.player4PPBetTitle:Hide()
        playerFrame.player4213BetTitle:Hide()
        playerFrame.player4InsuranceTitle:Hide()
        playerFrame.player4InsuranceSubtitle:Hide()
        menuFrame.cardsButton:Disable()
        playerFrame.historyButton:Disable()
        menuFrame.preloadButton:Disable()
        playerFrame.cashDeskButton:Disable()
        bankrollFrame.player4TotalBankrollTableDisplay:Hide()
        bankrollFrame.BaseTextDisplay:Show()
        cashDeskFrame.player4TotalBankroll:Hide()
        if gameRunning == false then
            playerFrame.player4Name:SetText("Seat Empty")
            SendChatMessage("{circle} " .. playerName .. " has left the table.", "RAID")
        else
            SendChatMessage("{skull} " .. playerName .. " exited the table before the round finished.", "RAID")
        end
        playerFrame.takeSeat4Button:Show()
        playerFrame.takeSeat4Button:Enable()
        if playerFrame.player1Name:GetText() == "Seat Empty" then    
            playerFrame.takeSeat1Button:Enable()
        end
        if playerFrame.player2Name:GetText() == "Seat Empty" then  
            playerFrame.takeSeat2Button:Enable()
        end
        if playerFrame.player3Name:GetText() == "Seat Empty" then 
            playerFrame.takeSeat3Button:Enable()
        end
        if playerFrame.player5Name:GetText() == "Seat Empty" then
            playerFrame.takeSeat5Button:Enable()
        end
    elseif playerName == unitName5 then
        playerFrame.leaveSeat5Button:Hide()
        playerFrame.player5HitButton:Hide()
        playerFrame.player5StandButton:Hide()
        playerFrame.player5DoubleButton:Hide()
        playerFrame.player5SplitButton:Hide()
        playerFrame.player5InsuranceYesButton:Hide()
        playerFrame.player5InsuranceNoButton:Hide()
        player5ConfirmMainBetButton:Hide()
        player5ConfirmPPBetButton:Hide()
        player5Confirm213BetButton:Hide()
        player5MainBetEditBox:Hide()
        player5PPBetEditBox:Hide()
        player5213BetEditBox:Hide()
        playerFrame.player5MainBetTitle:Hide()
        playerFrame.player5PPBetTitle:Hide()
        playerFrame.player5213BetTitle:Hide()
        playerFrame.player5InsuranceTitle:Hide()
        playerFrame.player5InsuranceSubtitle:Hide()
        menuFrame.cardsButton:Disable()
        playerFrame.historyButton:Disable()
        menuFrame.preloadButton:Disable()
        playerFrame.cashDeskButton:Disable()
        bankrollFrame.player5TotalBankrollTableDisplay:Hide()
        bankrollFrame.BaseTextDisplay:Show()
        cashDeskFrame.player5TotalBankroll:Hide()
        if gameRunning == false then
            playerFrame.player5Name:SetText("Seat Empty")
            SendChatMessage("{circle} " .. playerName .. " has left the table.", "RAID")
        else
            SendChatMessage("{skull} " .. playerName .. " exited the table before the round finished.", "RAID")
        end
        playerFrame.takeSeat5Button:Show()
        playerFrame.takeSeat5Button:Enable()
        if playerFrame.player1Name:GetText() == "Seat Empty" then    
            playerFrame.takeSeat1Button:Enable()
        end
        if playerFrame.player2Name:GetText() == "Seat Empty" then  
            playerFrame.takeSeat2Button:Enable()
        end
        if playerFrame.player3Name:GetText() == "Seat Empty" then 
            playerFrame.takeSeat3Button:Enable()
        end
        if playerFrame.player4Name:GetText() == "Seat Empty" then
            playerFrame.takeSeat4Button:Enable()
        end
    end
end)
function resetHistory()

    -- >>> PLAYER 1 <<<
    -- >>> PLAYER 1 <<<
    player1totalBetAmount = 0
    historyFrame.player1totalWageredAmount:SetText("0 G")
    player1totalWin = 0
    historyFrame.player1totalWonAmount:SetText("0 G")
    player1totalLoss = 0
    historyFrame.player1totalLostAmount:SetText("0 G")
    player1totalProfit = 0
    historyFrame.player1ProfitAmount:SetText("0 G")
    historyFrame.player1ProfitAmount:SetTextColor(1, 1, 1)
    player1TotalBankrollAmount = 0


    -- >>> PLAYER 2 <<<
    -- >>> PLAYER 2 <<<
    player2totalBetAmount = 0
    historyFrame.player2totalWageredAmount:SetText("0 G")
    player2totalWin = 0
    historyFrame.player2totalWonAmount:SetText("0 G")
    player2totalLoss = 0
    historyFrame.player2totalLostAmount:SetText("0 G")
    player2totalProfit = 0
    historyFrame.player2ProfitAmount:SetText("0 G")
    historyFrame.player2ProfitAmount:SetTextColor(1, 1, 1)
    player2TotalBankrollAmount = 0


    -- >>> PLAYER 3 <<<
    -- >>> PLAYER 3 <<<
    player3totalBetAmount = 0
    historyFrame.player3totalWageredAmount:SetText("0 G")
    player3totalWin = 0
    historyFrame.player3totalWonAmount:SetText("0 G")
    player3totalLoss = 0
    historyFrame.player3totalLostAmount:SetText("0 G")
    player3totalProfit = 0
    historyFrame.player3ProfitAmount:SetText("0 G")
    historyFrame.player3ProfitAmount:SetTextColor(1, 1, 1)
    player3TotalBankrollAmount = 0


    -- >>> PLAYER 4 <<<
    -- >>> PLAYER 4 <<<
    player4totalBetAmount = 0
    historyFrame.player4totalWageredAmount:SetText("0 G")
    player4totalWin = 0
    historyFrame.player4totalWonAmount:SetText("0 G")
    player4totalLoss = 0
    historyFrame.player4totalLostAmount:SetText("0 G")
    player4totalProfit = 0
    historyFrame.player4ProfitAmount:SetText("0 G")
    historyFrame.player4ProfitAmount:SetTextColor(1, 1, 1)
    player4TotalBankrollAmount = 0


    -- >>> PLAYER 5 <<<
    -- >>> PLAYER 5 <<<
    player5totalBetAmount = 0
    historyFrame.player5totalWageredAmount:SetText("0 G")
    player5totalWin = 0
    historyFrame.player5totalWonAmount:SetText("0 G")
    player5totalLoss = 0
    historyFrame.player5totalLostAmount:SetText("0 G")
    player5totalProfit = 0
    historyFrame.player5ProfitAmount:SetText("0 G")
    historyFrame.player5ProfitAmount:SetTextColor(1, 1, 1)
    player5TotalBankrollAmount = 0

end
function PlayerFrameHide()
    playerFrame:Hide()
    historyFrame:Hide()
    preloadFrame:Hide()
    payoutsFrame:Hide()
    sideBetWinFramePP:Hide()
    cashDeskFrame.returnButton:Disable()
    launchFrame2.joinButton:Disable()
    launchFrame2.tableStatus:SetText("Table: Closed")
end


















-- >>> PLAYER 1 <<<
-- >>> PLAYER 1 <<<
-- >>> PLAYER 1 <<<

playerFrame.player1CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", 385, 368)
playerFrame.player1CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 28, "OUTLINE")
playerFrame.player1CardTotalText:SetText("")

playerFrame.player1SplitHand1CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1SplitHand1CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", 410, 395)
playerFrame.player1SplitHand1CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
playerFrame.player1SplitHand1CardTotalText:SetText("")

playerFrame.player1SplitHand2CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1SplitHand2CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", 372, 355)
playerFrame.player1SplitHand2CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
playerFrame.player1SplitHand2CardTotalText:SetText("")

-- Buttons for Player 1
-- Hit
playerFrame.player1HitButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1HitButton:SetPoint("BOTTOM", playerFrame, 419, 275)
playerFrame.player1HitButton:SetSize(65, 30)
playerFrame.player1HitButton:SetText("Hit")
playerFrame.player1HitButton:Disable()
playerFrame.player1HitButton:Hide()
-- Stand
playerFrame.player1StandButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1StandButton:SetPoint("BOTTOM", playerFrame, 485, 275)
playerFrame.player1StandButton:SetSize(65, 30)
playerFrame.player1StandButton:SetText("Stand")
playerFrame.player1StandButton:Disable()
playerFrame.player1StandButton:Hide()
-- Double
playerFrame.player1DoubleButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1DoubleButton:SetPoint("BOTTOM", playerFrame, 419, 245)
playerFrame.player1DoubleButton:SetSize(65, 30)
playerFrame.player1DoubleButton:SetText("Double")
playerFrame.player1DoubleButton:Disable()
playerFrame.player1DoubleButton:Hide()
-- Split
playerFrame.player1SplitButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1SplitButton:SetPoint("BOTTOM", playerFrame, 485, 245)
playerFrame.player1SplitButton:SetSize(65, 30)
playerFrame.player1SplitButton:SetText("Split")
playerFrame.player1SplitButton:Disable()
playerFrame.player1SplitButton:Hide()
-- Insurance Yes
playerFrame.player1InsuranceYesButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1InsuranceYesButton:SetPoint("BOTTOM", playerFrame, 387, 215)
playerFrame.player1InsuranceYesButton:SetSize(55, 30)
playerFrame.player1InsuranceYesButton:SetText("Yes")
playerFrame.player1InsuranceYesButton:Disable()
playerFrame.player1InsuranceYesButton:Hide()
-- Insurance No
playerFrame.player1InsuranceNoButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1InsuranceNoButton:SetPoint("BOTTOM", playerFrame, 515, 215)
playerFrame.player1InsuranceNoButton:SetSize(55, 30)
playerFrame.player1InsuranceNoButton:SetText("No")
playerFrame.player1InsuranceNoButton:Disable()
playerFrame.player1InsuranceNoButton:Hide()
-- Deal Now
playerFrame.player1DealNowButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1DealNowButton:SetPoint("BOTTOM", playerFrame, 452, 215)
playerFrame.player1DealNowButton:SetSize(85, 30)
playerFrame.player1DealNowButton:SetText("Deal Now")
playerFrame.player1DealNowButton:Disable()
playerFrame.player1DealNowButton:Hide()
-- Hit (Split H1)
playerFrame.player1HitButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1HitButtonSplitH1:SetPoint("BOTTOM", playerFrame, 485, 275)
playerFrame.player1HitButtonSplitH1:SetSize(65, 30)
playerFrame.player1HitButtonSplitH1:SetText("Hit")
playerFrame.player1HitButtonSplitH1:Disable()
playerFrame.player1HitButtonSplitH1:Hide()
-- Stand (Split H1)
playerFrame.player1StandButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1StandButtonSplitH1:SetPoint("BOTTOM", playerFrame, 485, 245)
playerFrame.player1StandButtonSplitH1:SetSize(65, 30)
playerFrame.player1StandButtonSplitH1:SetText("Stand")
playerFrame.player1StandButtonSplitH1:Disable()
playerFrame.player1StandButtonSplitH1:Hide()
-- Double (Split H1)
playerFrame.player1DoubleButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1DoubleButtonSplitH1:SetPoint("BOTTOM", playerFrame, 485, 215)
playerFrame.player1DoubleButtonSplitH1:SetSize(65, 30)
playerFrame.player1DoubleButtonSplitH1:SetText("Double")
playerFrame.player1DoubleButtonSplitH1:Disable()
playerFrame.player1DoubleButtonSplitH1:Hide()
-- Hit (Split H2)
playerFrame.player1HitButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1HitButtonSplitH2:SetPoint("BOTTOM", playerFrame, 419, 275)
playerFrame.player1HitButtonSplitH2:SetSize(65, 30)
playerFrame.player1HitButtonSplitH2:SetText("Hit")
playerFrame.player1HitButtonSplitH2:Disable()
playerFrame.player1HitButtonSplitH2:Hide()
-- Stand (Split H2)
playerFrame.player1StandButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1StandButtonSplitH2:SetPoint("BOTTOM", playerFrame, 419, 245)
playerFrame.player1StandButtonSplitH2:SetSize(65, 30)
playerFrame.player1StandButtonSplitH2:SetText("Stand")
playerFrame.player1StandButtonSplitH2:Disable()
playerFrame.player1StandButtonSplitH2:Hide()
-- Double (Split H2)
playerFrame.player1DoubleButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player1DoubleButtonSplitH2:SetPoint("BOTTOM", playerFrame, 419, 215)
playerFrame.player1DoubleButtonSplitH2:SetSize(65, 30)
playerFrame.player1DoubleButtonSplitH2:SetText("Double")
playerFrame.player1DoubleButtonSplitH2:Disable()
playerFrame.player1DoubleButtonSplitH2:Hide()
-- Main Bet Confirm
player1ConfirmMainBetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player1ConfirmMainBetButton:SetPoint("BOTTOM", playerFrame, 485, 335)
player1ConfirmMainBetButton:SetSize(65, 30)
player1ConfirmMainBetButton:SetText("Bet")
player1ConfirmMainBetButton:Hide()
-- Perfect Pairs Confirm
player1ConfirmPPBetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player1ConfirmPPBetButton:SetPoint("BOTTOM", playerFrame, 309, 335)
player1ConfirmPPBetButton:SetSize(43, 25)
player1ConfirmPPBetButton:SetText("Bet")
player1ConfirmPPBetButton:Hide()
-- 21+3 Confirm
player1Confirm213BetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player1Confirm213BetButton:SetPoint("BOTTOM", playerFrame, 385, 470)
player1Confirm213BetButton:SetSize(43, 25)
player1Confirm213BetButton:SetText("Bet")
player1Confirm213BetButton:Hide()

-- Wagers for Player 1
-- Main Bet
player1MainBetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player1MainBetEditBox:SetSize(55, 30)
player1MainBetEditBox:SetPoint("BOTTOM", playerFrame, 422, 335)
player1MainBetEditBox:SetAutoFocus(false)
player1MainBetEditBox:SetNumeric(true)
player1MainBetEditBox:Hide()
-- Split Hand 1
player1SplitH1EditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player1SplitH1EditBox:SetSize(55, 30)
player1SplitH1EditBox:SetPoint("BOTTOM", playerFrame, 487, 335)
player1SplitH1EditBox:SetAutoFocus(false)
player1SplitH1EditBox:SetNumeric(true)
player1SplitH1EditBox:ClearFocus()
player1SplitH1EditBox:Disable()
player1SplitH1EditBox:Hide()
-- Split Hand 2
player1SplitH2EditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player1SplitH2EditBox:SetSize(55, 30)
player1SplitH2EditBox:SetPoint("BOTTOM", playerFrame, 422, 335)
player1SplitH2EditBox:SetAutoFocus(false)
player1SplitH2EditBox:SetNumeric(true)
player1SplitH2EditBox:ClearFocus()
player1SplitH2EditBox:Disable()
player1SplitH2EditBox:Hide()
-- Perfect Pairs
player1PPBetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player1PPBetEditBox:SetSize(35, 30)
player1PPBetEditBox:SetPoint("BOTTOM", playerFrame, 312, 355)
player1PPBetEditBox:SetAutoFocus(false)
player1PPBetEditBox:SetNumeric(true)
player1PPBetEditBox:Hide()
-- 21+3
player1213BetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player1213BetEditBox:SetSize(35, 30)
player1213BetEditBox:SetPoint("BOTTOM", playerFrame, 388, 490)
player1213BetEditBox:SetAutoFocus(false)
player1213BetEditBox:SetNumeric(true)
player1213BetEditBox:Hide()

-- Labels for Player 1
-- Main Bet
playerFrame.player1MainBetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1MainBetTitle:SetPoint("BOTTOM", playerFrame, 421, 362)
playerFrame.player1MainBetTitle:SetJustifyH("CENTER")
playerFrame.player1MainBetTitle:SetText("Main Bet")
playerFrame.player1MainBetTitle:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player1MainBetTitle:Hide()
-- Split Hand 1
playerFrame.player1SplitH1Title = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1SplitH1Title:SetPoint("BOTTOM", playerFrame, 486, 362)
playerFrame.player1SplitH1Title:SetJustifyH("CENTER")
playerFrame.player1SplitH1Title:SetText("Hand 1")
playerFrame.player1SplitH1Title:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player1SplitH1Title:Hide()
-- Split Hand 2
playerFrame.player1SplitH2Title = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1SplitH2Title:SetPoint("BOTTOM", playerFrame, 421, 362)
playerFrame.player1SplitH2Title:SetJustifyH("CENTER")
playerFrame.player1SplitH2Title:SetText("Hand 2")
playerFrame.player1SplitH2Title:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player1SplitH2Title:Hide()
-- Main Bet Amount
player1MainBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1MainBetAmount:SetPoint("CENTER", playerFrame, 338, 100)
player1MainBetAmount:SetJustifyH("CENTER")
player1MainBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Split Hand 1 Amount
player1SplitH1BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1SplitH1BetAmount:SetPoint("CENTER", playerFrame, 355, 115)
player1SplitH1BetAmount:SetJustifyH("CENTER")
player1SplitH1BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Split Hand 2 Amount
player1SplitH2BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1SplitH2BetAmount:SetPoint("CENTER", playerFrame, 327, 91)
player1SplitH2BetAmount:SetJustifyH("CENTER")
player1SplitH2BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Perfect Pairs
playerFrame.player1PPBetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1PPBetTitle:SetPoint("BOTTOM", playerFrame, 276, 353)
playerFrame.player1PPBetTitle:SetJustifyH("CENTER")
playerFrame.player1PPBetTitle:SetText("PP")
playerFrame.player1PPBetTitle:SetFont("Fonts\\FRIZQT__.TTF", 15, "OUTLINE")
playerFrame.player1PPBetTitle:Hide()
-- Perfect Pairs Amount
player1PPBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1PPBetAmount:SetPoint("CENTER", playerFrame, 275, 60)
player1PPBetAmount:SetJustifyH("CENTER")
player1PPBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- 21+3
playerFrame.player1213BetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1213BetTitle:SetPoint("BOTTOM", playerFrame, 430, 488)
playerFrame.player1213BetTitle:SetJustifyH("CENTER")
playerFrame.player1213BetTitle:SetText("21+3")
playerFrame.player1213BetTitle:SetFont("Fonts\\FRIZQT__.TTF", 15, "OUTLINE")
playerFrame.player1213BetTitle:Hide()
-- 21+3 Amount
player1213BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1213BetAmount:SetPoint("CENTER", playerFrame, 345, 156)
player1213BetAmount:SetJustifyH("CENTER")
player1213BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Insurance Amount
playerFrame.player1InsuranceBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1InsuranceBetAmount:SetPoint("CENTER", playerFrame, 559, -110)
playerFrame.player1InsuranceBetAmount:SetJustifyH("CENTER")
playerFrame.player1InsuranceBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
-- Player Name
playerFrame.player1Name = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1Name:SetPoint("BOTTOM", playerFrame, 452, 311)
playerFrame.player1Name:SetText("Seat Empty")
playerFrame.player1Name:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
-- Insurance
playerFrame.player1InsuranceTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1InsuranceTitle:SetPoint("BOTTOM", playerFrame, 452, 229) 
playerFrame.player1InsuranceTitle:SetText("Insurance")
playerFrame.player1InsuranceTitle:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
playerFrame.player1InsuranceTitle:Hide()
-- Insurance (if available)
playerFrame.player1InsuranceSubtitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1InsuranceSubtitle:SetPoint("BOTTOM", playerFrame, 452, 219)
playerFrame.player1InsuranceSubtitle:SetText("(if available)")
playerFrame.player1InsuranceSubtitle:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player1InsuranceSubtitle:Hide()
-- Session Win Update
playerFrame.player1WinningsUpdate = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player1WinningsUpdate:SetPoint("BOTTOMLEFT", playerFrame, 270, 30) 
playerFrame.player1WinningsUpdate:SetText("")
playerFrame.player1WinningsUpdate:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
playerFrame.player1WinningsUpdate:SetTextColor(0.118, 0.839, 0.412)

-- Images for Player 1
-- Turn Arrow
playerFrame.player1TurnArrow = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1TurnArrow:SetSize(128, 128)
playerFrame.player1TurnArrow:SetPoint("CENTER", playerFrame, 560, -15)
playerFrame.player1TurnArrow:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\TurnArrow.tga")
playerFrame.player1TurnArrow:SetBlendMode("BLEND")
playerFrame.player1TurnArrow:SetDrawLayer("OVERLAY")
playerFrame.player1TurnArrow:Hide()
-- Main Bet
playerFrame.player1MainBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1MainBetCoins:SetSize(128, 128)
playerFrame.player1MainBetCoins:SetPoint("CENTER", playerFrame, 355, 70)
playerFrame.player1MainBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player1MainBetCoins:SetBlendMode("BLEND")
playerFrame.player1MainBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player1MainBetCoins:Hide()
-- Win
playerFrame.player1NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1NormalWinCoins:SetSize(128, 128)
playerFrame.player1NormalWinCoins:SetPoint("CENTER", playerFrame, 355, 70)
playerFrame.player1NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player1NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player1NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player1NormalWinCoins:Hide()
-- Split Hand 2 Bet
playerFrame.player1SplitHand2Coins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1SplitHand2Coins:SetSize(128, 128)
playerFrame.player1SplitHand2Coins:SetPoint("CENTER", playerFrame, 345, 58)
playerFrame.player1SplitHand2Coins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player1SplitHand2Coins:SetBlendMode("BLEND")
playerFrame.player1SplitHand2Coins:SetDrawLayer("OVERLAY")
playerFrame.player1SplitHand2Coins:Hide()
-- Split Double Hand 2 Bet
playerFrame.player1SplitHand2DoubleCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1SplitHand2DoubleCoins:SetSize(128, 128)
playerFrame.player1SplitHand2DoubleCoins:SetPoint("CENTER", playerFrame, 345, 58)
playerFrame.player1SplitHand2DoubleCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player1SplitHand2DoubleCoins:SetBlendMode("BLEND")
playerFrame.player1SplitHand2DoubleCoins:SetDrawLayer("OVERLAY")
playerFrame.player1SplitHand2DoubleCoins:Hide()
-- Split Win Hand 2
playerFrame.player1SplitHand2NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1SplitHand2NormalWinCoins:SetSize(128, 128)
playerFrame.player1SplitHand2NormalWinCoins:SetPoint("CENTER", playerFrame, 345, 58)
playerFrame.player1SplitHand2NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player1SplitHand2NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player1SplitHand2NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player1SplitHand2NormalWinCoins:Hide()
-- Split Hand 1 Bet
playerFrame.player1SplitHand1Coins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1SplitHand1Coins:SetSize(128, 128)
playerFrame.player1SplitHand1Coins:SetPoint("CENTER", playerFrame, 372, 83)
playerFrame.player1SplitHand1Coins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player1SplitHand1Coins:SetBlendMode("BLEND")
playerFrame.player1SplitHand1Coins:SetDrawLayer("OVERLAY")
playerFrame.player1SplitHand1Coins:Hide()
-- Split Double Hand 1 Bet
playerFrame.player1SplitHand1DoubleCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1SplitHand1DoubleCoins:SetSize(128, 128)
playerFrame.player1SplitHand1DoubleCoins:SetPoint("CENTER", playerFrame, 372, 83)
playerFrame.player1SplitHand1DoubleCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player1SplitHand1DoubleCoins:SetBlendMode("BLEND")
playerFrame.player1SplitHand1DoubleCoins:SetDrawLayer("OVERLAY")
playerFrame.player1SplitHand1DoubleCoins:Hide()
-- Split Win Hand 1
playerFrame.player1SplitHand1NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1SplitHand1NormalWinCoins:SetSize(128, 128)
playerFrame.player1SplitHand1NormalWinCoins:SetPoint("CENTER", playerFrame, 372, 83)
playerFrame.player1SplitHand1NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player1SplitHand1NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player1SplitHand1NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player1SplitHand1NormalWinCoins:Hide()
-- Blackjack Win
playerFrame.player1BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1BJWinCoins:SetSize(128, 128)
playerFrame.player1BJWinCoins:SetPoint("CENTER", playerFrame, 355, 70)
playerFrame.player1BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player1BJWinCoins:SetBlendMode("BLEND")
playerFrame.player1BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player1BJWinCoins:Hide()
-- Split BJ Win Hand 2
playerFrame.player1SplitHand2BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1SplitHand2BJWinCoins:SetSize(128, 128)
playerFrame.player1SplitHand2BJWinCoins:SetPoint("CENTER", playerFrame, 345, 58)
playerFrame.player1SplitHand2BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player1SplitHand2BJWinCoins:SetBlendMode("BLEND")
playerFrame.player1SplitHand2BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player1SplitHand2BJWinCoins:Hide()
-- Split BJ Win Hand 1
playerFrame.player1SplitHand1BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1SplitHand1BJWinCoins:SetSize(128, 128)
playerFrame.player1SplitHand1BJWinCoins:SetPoint("CENTER", playerFrame, 372, 83)
playerFrame.player1SplitHand1BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player1SplitHand1BJWinCoins:SetBlendMode("BLEND")
playerFrame.player1SplitHand1BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player1SplitHand1BJWinCoins:Hide()
-- Double Bet
playerFrame.player1DoubleBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1DoubleBetCoins:SetSize(128, 128)
playerFrame.player1DoubleBetCoins:SetPoint("CENTER", playerFrame, 355, 70)
playerFrame.player1DoubleBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player1DoubleBetCoins:SetBlendMode("BLEND")
playerFrame.player1DoubleBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player1DoubleBetCoins:Hide()
-- PP Bet
playerFrame.player1PPBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1PPBetCoins:SetSize(128, 128)
playerFrame.player1PPBetCoins:SetPoint("CENTER", playerFrame, 280, 40)
playerFrame.player1PPBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsHalfBet.tga")
playerFrame.player1PPBetCoins:SetBlendMode("BLEND")
playerFrame.player1PPBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player1PPBetCoins:Hide()
-- 21+3 Bet
playerFrame.player1213BetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1213BetCoins:SetSize(128, 128)
playerFrame.player1213BetCoins:SetPoint("CENTER", playerFrame, 350, 136)
playerFrame.player1213BetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsHalfBet.tga")
playerFrame.player1213BetCoins:SetBlendMode("BLEND")
playerFrame.player1213BetCoins:SetDrawLayer("OVERLAY")
playerFrame.player1213BetCoins:Hide()
-- PP Win
playerFrame.player1PPWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1PPWinCoins:SetSize(128, 128)
playerFrame.player1PPWinCoins:SetPoint("CENTER", playerFrame, 292, 44)
playerFrame.player1PPWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player1PPWinCoins:SetBlendMode("BLEND")
playerFrame.player1PPWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player1PPWinCoins:Hide()
-- 21+3 Win
playerFrame.player1213WinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player1213WinCoins:SetSize(128, 128)
playerFrame.player1213WinCoins:SetPoint("CENTER", playerFrame, 361, 141)
playerFrame.player1213WinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player1213WinCoins:SetBlendMode("BLEND")
playerFrame.player1213WinCoins:SetDrawLayer("OVERLAY")
playerFrame.player1213WinCoins:Hide()
-- Insurance YES for Player 1
player1InsuranceYesIcon = playerFrame:CreateTexture(nil, "OVERLAY")
player1InsuranceYesIcon:SetSize(24, 24)
player1InsuranceYesIcon:SetPoint("CENTER", playerFrame, 556, -129)
player1InsuranceYesIcon:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\insuranceYes.tga")
player1InsuranceYesIcon:SetDrawLayer("ARTWORK")
player1InsuranceYesIcon:Hide()
-- Insurance NO for Player 1
player1InsuranceNoIcon = playerFrame:CreateTexture(nil, "OVERLAY")
player1InsuranceNoIcon:SetSize(24, 24)
player1InsuranceNoIcon:SetPoint("CENTER", playerFrame, 556, -129)
player1InsuranceNoIcon:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\insuranceNo.tga")
player1InsuranceNoIcon:SetDrawLayer("ARTWORK")
player1InsuranceNoIcon:Hide()

-- BJ Win Coins
function player1PlaceCoinsBJWin(message)
    playerFrame.player1MainBetCoins:Hide()
    playerFrame.player1BJWinCoins:Show()
end

-- Regular Win Coins
function player1PlaceCoinsRegularWin(message)
    playerFrame.player1MainBetCoins:Hide()
    playerFrame.player1DoubleBetCoins:Show()
end

-- Main Bet Coins
function player1PlaceCoinsMainBet(message)
    playerFrame.player1MainBetCoins:Show()
end

-- Double Bet Coins
function player1PlaceCoinsDoubleBet(message)
    playerFrame.player1MainBetCoins:Hide()
    playerFrame.player1DoubleBetCoins:Show()
end

-- Function to handle Player 1 Main Bet Text
function player1PlaceTextMainBet(message)
    player1HistoryMainBet = string.match(message, "(%d+)G")

        if player1HistoryMainBet then
            player1MainBetAmount:SetText(player1HistoryMainBet .. " G")
            player1MainBetAmount:Show()

            if playerName == unitName1 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName1]
                    player1totalBetAmount = player1totalBetAmount + tonumber(player1HistoryMainBet)
                    bankingInfo.totalWagered = player1totalBetAmount
                end
            end

            historyFrame.player1totalWageredAmount:SetText(player1totalBetAmount .. " G")

        else
    end
end

-- Player 1 Split Hand Bet Text
function player1SplitHand1BetText(Amount)
    player1MainBetAmount:Hide()
    player1MainBetAmount:SetText("")
    player1SplitH1BetAmount:SetText(Amount .. " G")
    player1SplitH1BetAmount:Show()
    player1SplitH2BetAmount:SetText(Amount .. " G")
    player1SplitH2BetAmount:Show()
end

-- Player 1 Split Bet Image
function player1PlaceSplitBet(message)
    playerFrame.player1MainBetCoins:Hide()
    playerFrame.player1SplitHand1Coins:Show()
    playerFrame.player1SplitHand2Coins:Show()
end

-- Player 1 Place Initial Card Images
function player1PlaceSplitCards(message)

    -- Players: 1
    if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
        drawnCards[1]:Hide()
        drawnCards[3]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[3]
        turn = 8 -- Player 1: 2nd Card (Split H1)

    -- Players: 1, 2
    elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
        drawnCards[1]:Hide()
        drawnCards[4]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[4]
        turn = 10 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 3
    elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
        drawnCards[1]:Hide()
        drawnCards[4]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[4]
        turn = 10 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 4
    elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
        drawnCards[1]:Hide()
        drawnCards[4]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[4]
        turn = 10 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 5
    elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
        drawnCards[1]:Hide()
        drawnCards[4]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[4]
        turn = 10 -- Player 1: 2nd Card (Split H1)

    -- Players: 1, 2, 3
    elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
        drawnCards[1]:Hide()
        drawnCards[5]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[5]
        turn = 12 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 2, 4
    elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
        drawnCards[1]:Hide()
        drawnCards[5]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[5]
        turn = 12 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 2, 5
    elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
        drawnCards[1]:Hide()
        drawnCards[5]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[5]
        turn = 12 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 3, 4
    elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
        drawnCards[1]:Hide()
        drawnCards[5]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[5]
        turn = 12 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 3, 5
    elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
        drawnCards[1]:Hide()
        drawnCards[5]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[5]
        turn = 12 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 4, 5
    elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
        drawnCards[1]:Hide()
        drawnCards[5]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[5]
        turn = 12 -- Player 1: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4
    elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
        drawnCards[1]:Hide()
        drawnCards[6]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[6]
        turn = 14 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 2, 3, 5
    elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
        drawnCards[1]:Hide()
        drawnCards[6]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[6]
        turn = 14 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 2, 4, 5
    elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
        drawnCards[1]:Hide()
        drawnCards[6]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[6]
        turn = 14 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 3, 4, 5
    elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
        drawnCards[1]:Hide()
        drawnCards[6]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[6]
        turn = 14 -- Player 1: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4, 5
    elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
        drawnCards[1]:Hide()
        drawnCards[7]:Hide()
        player1cardName1 = dealtCards[1]
        player1cardName2 = dealtCards[6]
        turn = 16 -- Player 1: 2nd Card (Split H1)
    end

    player1cardImageFile1 = nil
    player1cardImageFile2 = nil

    for filename, cardDescription in pairs(cardNames) do
        if cardDescription == player1cardName1 then
            player1cardImageFile1 = filename
            break
        end
    end

    for filename, cardDescription in pairs(cardNames) do
        if cardDescription == player1cardName2 then
            player1cardImageFile2 = filename
            break
        end
    end

    player1NewCardImage1 = CreateFrame("Frame", nil, playerFrame)
    player1NewCardImage1:SetSize(32, 64)
    player1NewCardImage1:SetPoint("BOTTOM", playerFrame, 302, 454)
    player1NewCardImage1.texture = player1NewCardImage1:CreateTexture()
    player1NewCardImage1.texture:SetAllPoints()
    player1NewCardImage1.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1cardImageFile1)
    player1NewCardImage1:Show()

    player1NewCardImage2 = CreateFrame("Frame", nil, playerFrame)
    player1NewCardImage2:SetSize(32, 64)
    player1NewCardImage2:SetPoint("BOTTOM", playerFrame, 265, 435)
    player1NewCardImage2.texture = player1NewCardImage2:CreateTexture()
    player1NewCardImage2.texture:SetAllPoints()
    player1NewCardImage2.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1cardImageFile2)
    player1NewCardImage2:Show()

end

-- Player 1 Split Function
function player1HandleSplit(message)
    player1PlaceSplitBet()
    player1MainBetAmountValue = tonumber(string.match(player1MainBetAmount:GetText(), "%d+"))
    if player1MainBetAmountValue then
        player1SplitHand1BetText(player1MainBetAmountValue)
    end 

    player1PlaceSplitCards()

    -- A,A
    if playerFrame.player1CardTotalText:GetText() == "2 or 12" then
        playerFrame.player1SplitHand1CardTotalText:SetText("1 or 11")
        playerFrame.player1SplitHand1CardTotalText:Show()
        playerFrame.player1SplitHand2CardTotalText:SetText("1 or 11")
        playerFrame.player1SplitHand2CardTotalText:Show()
    -- 2,2
    elseif playerFrame.player1CardTotalText:GetText() == "4" then
        playerFrame.player1SplitHand1CardTotalText:SetText("2")
        playerFrame.player1SplitHand1CardTotalText:Show()
        playerFrame.player1SplitHand2CardTotalText:SetText("2")
        playerFrame.player1SplitHand2CardTotalText:Show()
    -- 3,3
    elseif playerFrame.player1CardTotalText:GetText() == "6" then
        playerFrame.player1SplitHand1CardTotalText:SetText("3")
        playerFrame.player1SplitHand1CardTotalText:Show()
        playerFrame.player1SplitHand2CardTotalText:SetText("3")
        playerFrame.player1SplitHand2CardTotalText:Show()
    -- 4,4
    elseif playerFrame.player1CardTotalText:GetText() == "8" then
        playerFrame.player1SplitHand1CardTotalText:SetText("4")
        playerFrame.player1SplitHand1CardTotalText:Show()
        playerFrame.player1SplitHand2CardTotalText:SetText("4")
        playerFrame.player1SplitHand2CardTotalText:Show()
    -- 5,5
    elseif playerFrame.player1CardTotalText:GetText() == "10" then
        playerFrame.player1SplitHand1CardTotalText:SetText("5")
        playerFrame.player1SplitHand1CardTotalText:Show()
        playerFrame.player1SplitHand2CardTotalText:SetText("5")
        playerFrame.player1SplitHand2CardTotalText:Show()
    -- 6,6
    elseif playerFrame.player1CardTotalText:GetText() == "12" then
        playerFrame.player1SplitHand1CardTotalText:SetText("6")
        playerFrame.player1SplitHand1CardTotalText:Show()
        playerFrame.player1SplitHand2CardTotalText:SetText("6")
        playerFrame.player1SplitHand2CardTotalText:Show()
    -- 7,7
    elseif playerFrame.player1CardTotalText:GetText() == "14" then
        playerFrame.player1SplitHand1CardTotalText:SetText("7")
        playerFrame.player1SplitHand1CardTotalText:Show()
        playerFrame.player1SplitHand2CardTotalText:SetText("7")
        playerFrame.player1SplitHand2CardTotalText:Show()
    -- 8,8
    elseif playerFrame.player1CardTotalText:GetText() == "16" then
        playerFrame.player1SplitHand1CardTotalText:SetText("8")
        playerFrame.player1SplitHand1CardTotalText:Show()
        playerFrame.player1SplitHand2CardTotalText:SetText("8")
        playerFrame.player1SplitHand2CardTotalText:Show()
    -- 9,9
    elseif playerFrame.player1CardTotalText:GetText() == "18" then
        playerFrame.player1SplitHand1CardTotalText:SetText("9")
        playerFrame.player1SplitHand1CardTotalText:Show()
        playerFrame.player1SplitHand2CardTotalText:SetText("9")
        playerFrame.player1SplitHand2CardTotalText:Show()
    -- 10,10
    elseif playerFrame.player1CardTotalText:GetText() == "20" then
        playerFrame.player1SplitHand1CardTotalText:SetText("10")
        playerFrame.player1SplitHand1CardTotalText:Show()
        playerFrame.player1SplitHand2CardTotalText:SetText("10")
        playerFrame.player1SplitHand2CardTotalText:Show()
    end

    playerFrame.player1CardTotalText:SetText("")
    playerFrame.player1CardTotalText:Hide()
    
    if playerName == unitName1 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player1totalBetAmount = player1totalBetAmount + tonumber(player1MainBetAmountValue)
            bankingInfo.totalWagered = player1totalBetAmount
            player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(player1MainBetAmountValue)
            bankingInfo.bankrollTable = player1TotalBankrollAmount
        end
    end

    historyFrame.player1totalWageredAmount:SetText(player1totalBetAmount .. " G")
    bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
    cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

    player1SplitToggle = true

    if player1dealtCardsFrame:IsShown() then
        player1dealtCardsFrame:Hide()
        player1dealtCardsFrame.playerCardsButton:Hide()
        player1dealtCardsFrameSplitH1:Show()
        player1dealtCardsFrameSplitH1.playerH1CardsButton:Show()
    end

end

-- Function to handle Player 1 PP Bet Image
function player1PlaceCoinsPPBet(message)
    playerFrame.player1PPBetCoins:Show()
end

-- Function to handle Player 1 PP Bet Text
function player1PlaceTextPPBet(message)
    player1HistoryPPBet = string.match(message, "(%d+)G")

        if player1HistoryPPBet then
            player1PPBetAmount:SetText(player1HistoryPPBet .. " G")
            player1PPBetAmount:Show()

            if playerName == unitName1 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName1]
                    player1totalBetAmount = player1totalBetAmount + tonumber(player1HistoryPPBet)
                    bankingInfo.totalWagered = player1totalBetAmount
                end
            end

            historyFrame.player1totalWageredAmount:SetText(player1totalBetAmount .. " G")

        else
    end
end

-- Function to handle Player 1 21+3 Bet Image
function player1PlaceCoins213Bet(message)
    playerFrame.player1213BetCoins:Show()
end

-- Function to handle Player 1 21+3 Bet Text
function player1PlaceText213Bet(message)
    player1History213Bet = string.match(message, "(%d+)G")

        if player1History213Bet then
            player1213BetAmount:SetText(player1History213Bet .. " G")
            player1213BetAmount:Show()

            if playerName == unitName1 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName1]
                    player1totalBetAmount = player1totalBetAmount + tonumber(player1History213Bet)
                    bankingInfo.totalWagered = player1totalBetAmount
                end
            end

            historyFrame.player1totalWageredAmount:SetText(player1totalBetAmount .. " G")

        else
    end
end

function player1PreloadBet()
    
    player1MainBet = tonumber(player1PreloadEditBoxMainBet:GetText()) or 0
    player1PPBet = tonumber(player1PreloadEditBoxPPBet:GetText()) or 0
    player1213Bet = tonumber(player1PreloadEditBox213Bet:GetText()) or 0

    player1TotalRebetAmount = player1MainBet + player1PPBet + player1213Bet

    player1currentBankroll = tonumber(string.match(bankrollFrame.player1TotalBankrollTableDisplay:GetText(), "%d+"))

    if player1currentBankroll - player1TotalRebetAmount < 0 then
        print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
    else
        player1Threshold = minBetMain - 1
        if player1MainBet <= player1Threshold then
            print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
        else
            if player1MainBet and player1MainBet >= minBetMain and player1MainBet <= maxBetMain then
                PlaySoundFile(soundFilePaths[33])
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P1] PIacing a " ..player1MainBet.. "G main bet.", "RAID")
                -- Disable the edit box and button
                player1PreloadEditBoxMainBet:SetFocus(false)
                player1PreloadEditBoxMainBet:ClearFocus()
                player1MainBetEditBox:SetText("")
                player1MainBetEditBox:SetText(player1MainBet)
                player1MainBetEditBox:SetFocus(false)
                player1MainBetEditBox:ClearFocus()
                player1MainBetEditBox:Disable()
                player1ConfirmMainBetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(player1MainBet)
                    bankingInfo.bankrollTable = player1TotalBankrollAmount
                end
            end

            if player1PPBet and player1PPBet >= minBetPP and player1PPBet <= maxBetPP then
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P1] PIacing a " ..player1PPBet.. "G side bet on Perfect Pairs.", "RAID")
                -- Disable the edit box and button
                player1PreloadEditBoxPPBet:SetFocus(false)
                player1PreloadEditBoxPPBet:ClearFocus()
                player1PPBetEditBox:SetText("")
                player1PPBetEditBox:SetText(player1PPBet)
                player1PPBetEditBox:SetFocus(false)
                player1PPBetEditBox:ClearFocus()
                player1PPBetEditBox:Disable()
                player1ConfirmPPBetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(player1PPBet)
                    bankingInfo.bankrollTable = player1TotalBankrollAmount
                end
            end

            if player1213Bet and player1213Bet >= minBet213 and player1213Bet <= maxBet213 then
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P1] PIacing a " ..player1213Bet.. "G side bet on 21+3.", "RAID")
                -- Disable the edit box and button
                player1PreloadEditBox213Bet:SetFocus(false)
                player1PreloadEditBox213Bet:ClearFocus()
                player1213BetEditBox:SetText("")
                player1213BetEditBox:SetText(player1213Bet)
                player1213BetEditBox:SetFocus(false)
                player1213BetEditBox:ClearFocus()
                player1213BetEditBox:Disable()
                player1Confirm213BetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(player1213Bet)
                    bankingInfo.bankrollTable = player1TotalBankrollAmount
                end
            end

            player1PreloadBetButton:Disable()

        end

        bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

    end

end

-- Function to handle the Player 1 Main "Bet" button click
function player1ConfirmMainBetClick()
    player1MainBet = tonumber(player1MainBetEditBox:GetText())
    player1currentBankroll = tonumber(string.match(bankrollFrame.player1TotalBankrollTableDisplay:GetText(), "%d+"))

    if player1MainBet and player1MainBet >= minBetMain and player1MainBet <= maxBetMain then
        if player1currentBankroll - player1MainBet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            -- Valid bet amount, send the message with the bet
            SendChatMessage("[P1] PIacing a " ..player1MainBet.. "G main bet.", "RAID")
            -- Disable the edit box and button
            player1MainBetEditBox:SetFocus(false)
            player1MainBetEditBox:ClearFocus()
            player1MainBetEditBox:Disable()
            player1ConfirmMainBetButton:Disable()

            player1PreloadBetButton:Disable()

            PlaySoundFile(soundFilePaths[33]) 

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(player1MainBet)
                bankingInfo.bankrollTable = player1TotalBankrollAmount
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBetMain .. "G and " .. maxBetMain .. "G.")
    end

end

-- Function to handle the Player 1 PP "Bet" button click
function player1ConfirmPPBetClick()
    player1PPBet = tonumber(player1PPBetEditBox:GetText()) -- Get the entered bet amount
    player1currentBankroll = tonumber(string.match(bankrollFrame.player1TotalBankrollTableDisplay:GetText(), "%d+"))

    if player1PPBet and player1PPBet >= minBetPP and player1PPBet <= maxBetPP then
        if player1currentBankroll - player1PPBet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            if not player1Active then
                print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
            else
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P1] PIacing a " ..player1PPBet.. "G side bet on Perfect Pairs.", "RAID")
                -- Disable the edit box and button
                player1PPBetEditBox:SetFocus(false)
                player1PPBetEditBox:ClearFocus()
                player1PPBetEditBox:Disable()
                player1ConfirmPPBetButton:Disable()

                player1PreloadBetButton:Disable()

                PlaySoundFile(soundFilePaths[33])

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(player1PPBet)
                    bankingInfo.bankrollTable = player1TotalBankrollAmount
                end

                bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
                cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

            end
        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBetPP .. "G and " .. maxBetPP .. "G.")
    end

end

-- Function to handle the Player 1 21+3 "Bet" button click
function player1Confirm213BetClick()
    player1213Bet = tonumber(player1213BetEditBox:GetText()) -- Get the entered bet amount
    player1currentBankroll = tonumber(string.match(bankrollFrame.player1TotalBankrollTableDisplay:GetText(), "%d+"))

    if player1213Bet and player1213Bet >= minBet213 and player1213Bet <= maxBet213 then
        if player1currentBankroll - player1213Bet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            if not player1Active then
                print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
            else
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P1] PIacing a " ..player1213Bet.. "G side bet on 21+3.", "RAID")
                -- Disable the edit box and button
                player1213BetEditBox:SetFocus(false)
                player1213BetEditBox:ClearFocus()
                player1213BetEditBox:Disable()
                player1Confirm213BetButton:Disable()

                player1PreloadBetButton:Disable()

                PlaySoundFile(soundFilePaths[33])

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(player1213Bet)
                    bankingInfo.bankrollTable = player1TotalBankrollAmount
                end

                bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
                cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

            end
        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBet213 .. "G and " .. maxBet213 .. "G.")
    end
 
end

-- Player 1 Main "Bet" button
player1ConfirmMainBetButton:SetScript("OnClick", player1ConfirmMainBetClick)

-- Player 1 PP "Bet" button
player1ConfirmPPBetButton:SetScript("OnClick", player1ConfirmPPBetClick)

-- Player 1 21+3 "Bet" button
player1Confirm213BetButton:SetScript("OnClick", player1Confirm213BetClick)

-- Player 1 "Bet All" Preload button
player1PreloadBetButton:SetScript("OnClick", player1PreloadBet)

function player1resetRaidChannel()
    if playerName == unitName1 then
        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/raid", chatFrame)
        
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:SetText("")
        editBox:Insert("/raid")
        
        ChatEdit_SendText(editBox)
        ChatEdit_DeactivateChat(editBox)
    else
        print("")
    end
end

player1HotstreakImage1 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage1:SetSize(36, 36)
player1HotstreakImage1:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak1.tga")
player1HotstreakImage1:SetDrawLayer("OVERLAY")
player1HotstreakImage1:Hide()

player1HotstreakImage2 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage2:SetSize(36, 36)
player1HotstreakImage2:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak2.tga")
player1HotstreakImage2:SetDrawLayer("OVERLAY")
player1HotstreakImage2:Hide()

player1HotstreakImage3 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage3:SetSize(36, 36)
player1HotstreakImage3:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak3.tga")
player1HotstreakImage3:SetDrawLayer("OVERLAY")
player1HotstreakImage3:Hide()

player1HotstreakImage4 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage4:SetSize(36, 36)
player1HotstreakImage4:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak4.tga")
player1HotstreakImage4:SetDrawLayer("OVERLAY")
player1HotstreakImage4:Hide()

player1HotstreakImage5 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage5:SetSize(36, 36)
player1HotstreakImage5:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak5.tga")
player1HotstreakImage5:SetDrawLayer("OVERLAY")
player1HotstreakImage5:Hide()

player1HotstreakImage6 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage6:SetSize(36, 36)
player1HotstreakImage6:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak6.tga")
player1HotstreakImage6:SetDrawLayer("OVERLAY")
player1HotstreakImage6:Hide()

player1HotstreakImage7 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage7:SetSize(36, 36)
player1HotstreakImage7:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak7.tga")
player1HotstreakImage7:SetDrawLayer("OVERLAY")
player1HotstreakImage7:Hide()

player1HotstreakImage8 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage8:SetSize(36, 36)
player1HotstreakImage8:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage8:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak8.tga")
player1HotstreakImage8:SetDrawLayer("OVERLAY")
player1HotstreakImage8:Hide()

player1HotstreakImage9 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage9:SetSize(36, 36)
player1HotstreakImage9:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage9:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak9.tga")
player1HotstreakImage9:SetDrawLayer("OVERLAY")
player1HotstreakImage9:Hide()

player1HotstreakImage10 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage10:SetSize(36, 36)
player1HotstreakImage10:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage10:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak10.tga")
player1HotstreakImage10:SetDrawLayer("OVERLAY")
player1HotstreakImage10:Hide()

player1HotstreakImage11 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage11:SetSize(36, 36)
player1HotstreakImage11:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage11:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak11.tga")
player1HotstreakImage11:SetDrawLayer("OVERLAY")
player1HotstreakImage11:Hide()

player1HotstreakImage12 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage12:SetSize(36, 36)
player1HotstreakImage12:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage12:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak12.tga")
player1HotstreakImage12:SetDrawLayer("OVERLAY")
player1HotstreakImage12:Hide()

player1HotstreakImage13 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage13:SetSize(36, 36)
player1HotstreakImage13:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage13:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak13.tga")
player1HotstreakImage13:SetDrawLayer("OVERLAY")
player1HotstreakImage13:Hide()

player1HotstreakImage14 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage14:SetSize(36, 36)
player1HotstreakImage14:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage14:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak14.tga")
player1HotstreakImage14:SetDrawLayer("OVERLAY")
player1HotstreakImage14:Hide()

player1HotstreakImage15 = playerFrame:CreateTexture(nil, "OVERLAY")
player1HotstreakImage15:SetSize(36, 36)
player1HotstreakImage15:SetPoint("CENTER", playerFrame, 367, -79)
player1HotstreakImage15:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak15.tga")
player1HotstreakImage15:SetDrawLayer("OVERLAY")
player1HotstreakImage15:Hide()

function player1HotStreakCheck()
    if player1Hotstreak == 0 then
        player1HotstreakImage1:Hide()
        player1HotstreakImage2:Hide()
        player1HotstreakImage3:Hide()
        player1HotstreakImage4:Hide()
        player1HotstreakImage5:Hide()
        player1HotstreakImage6:Hide()
        player1HotstreakImage7:Hide()
        player1HotstreakImage8:Hide()
        player1HotstreakImage9:Hide()
        player1HotstreakImage10:Hide()
        player1HotstreakImage11:Hide()
        player1HotstreakImage12:Hide()
        player1HotstreakImage13:Hide()
        player1HotstreakImage14:Hide()
        player1HotstreakImage15:Hide()
    elseif player1Hotstreak == 1 then
        player1HotstreakImage1:Show()
    elseif player1Hotstreak == 2 then
        player1HotstreakImage1:Hide()
        player1HotstreakImage2:Show()
    elseif player1Hotstreak == 3 then
        player1HotstreakImage1:Hide()
        player1HotstreakImage2:Hide()
        player1HotstreakImage3:Show()
    elseif player1Hotstreak == 4 then
        player1HotstreakImage2:Hide()
        player1HotstreakImage3:Hide()
        player1HotstreakImage4:Show()
    elseif player1Hotstreak == 5 then
        player1HotstreakImage3:Hide()
        player1HotstreakImage4:Hide()
        player1HotstreakImage5:Show()
    elseif player1Hotstreak == 6 then
        player1HotstreakImage4:Hide()
        player1HotstreakImage5:Hide()
        player1HotstreakImage6:Show()
    elseif player1Hotstreak == 7 then
        player1HotstreakImage5:Hide()
        player1HotstreakImage6:Hide()
        player1HotstreakImage7:Show()
    elseif player1Hotstreak == 8 then
        player1HotstreakImage6:Hide()
        player1HotstreakImage7:Hide()
        player1HotstreakImage8:Show()
    elseif player1Hotstreak == 9 then
        player1HotstreakImage7:Hide()
        player1HotstreakImage8:Hide()
        player1HotstreakImage9:Show()
    elseif player1Hotstreak == 10 then
        player1HotstreakImage8:Hide()
        player1HotstreakImage9:Hide()
        player1HotstreakImage10:Show()
    elseif player1Hotstreak == 11 then
        player1HotstreakImage9:Hide()
        player1HotstreakImage10:Hide()
        player1HotstreakImage11:Show()
    elseif player1Hotstreak == 12 then
        player1HotstreakImage10:Hide()
        player1HotstreakImage11:Hide()
        player1HotstreakImage12:Show()
    elseif player1Hotstreak == 13 then
        player1HotstreakImage11:Hide()
        player1HotstreakImage12:Hide()
        player1HotstreakImage13:Show()
    elseif player1Hotstreak == 14 then
        player1HotstreakImage12:Hide()
        player1HotstreakImage13:Hide()
        player1HotstreakImage14:Show()
    elseif player1Hotstreak == 15 then
        player1HotstreakImage13:Hide()
        player1HotstreakImage14:Hide()
        player1HotstreakImage15:Show()
    end
end

-- Function to handle Player 1 PP Win Image
function player1PlaceBetsPPWin(message)
    playerFrame.player1PPBetCoins:Hide()
    playerFrame.player1PPWinCoins:Show()
    player1PPBetAmount:SetPoint("CENTER", playerFrame, 274, 77)
end

-- Function to handle Player 1 21+3 Win Image
function player1PlaceBets213Win(message)
    playerFrame.player1213BetCoins:Hide()
    playerFrame.player1213WinCoins:Show()
    player1213BetAmount:SetPoint("CENTER", playerFrame, 345, 174)
end

function player1MixedPairWin(message)

    if playerName == unitName1 then
        player1PPBetAmountValue = tonumber(string.match(player1PPBetEditBox:GetText(), "%d+"))
        if player1PPBetAmountValue then
            player1NewPPAmount = player1PPBetAmountValue * mixedPairPayoutReturn
            player1PPBetAmount:SetText(player1NewPPAmount .. " G")
            player1PPBetAmount:SetTextColor(0, 1, 0)

            player1PPProfitvalue = player1NewPPAmount - player1PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player1totalWin = player1totalWin + tonumber(player1PPProfitvalue)
                    bankingInfo.totalWon = player1totalWin
                    player1totalProfit = player1totalProfit + tonumber(player1PPProfitvalue)
                    bankingInfo.totalProfit = player1totalProfit
                    player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1NewPPAmount)
                    bankingInfo.bankrollTable = player1TotalBankrollAmount
                end

            historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
            historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
            if player1totalProfit >= 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        end
    else
        player1PPBetAmountValue = tonumber(string.match(player1PPBetAmount:GetText(), "%d+"))
        if player1PPBetAmountValue then
            player1NewPPAmount = player1PPBetAmountValue * mixedPairPayoutReturn
            player1PPBetAmount:SetText(player1NewPPAmount .. " G")
            player1PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player1PlaceBetsPPWin()
    player1PPSideBetWin = true

    player1SessionWin = player1SessionWin + tonumber(player1NewPPAmount)

end

function player1ColouredPairWin(message)

    if playerName == unitName1 then
        player1PPBetAmountValue = tonumber(string.match(player1PPBetEditBox:GetText(), "%d+"))
        if player1PPBetAmountValue then
            player1NewPPAmount = player1PPBetAmountValue * colouredPairPayoutReturn
            player1PPBetAmount:SetText(player1NewPPAmount .. " G")
            player1PPBetAmount:SetTextColor(0, 1, 0)

            player1PPProfitvalue = player1NewPPAmount - player1PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player1totalWin = player1totalWin + tonumber(player1PPProfitvalue)
                    bankingInfo.totalWon = player1totalWin
                    player1totalProfit = player1totalProfit + tonumber(player1PPProfitvalue)
                    bankingInfo.totalProfit = player1totalProfit
                    player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1NewPPAmount)
                    bankingInfo.bankrollTable = player1TotalBankrollAmount
                end

            historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
            historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
            if player1totalProfit >= 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        end
    else
        player1PPBetAmountValue = tonumber(string.match(player1PPBetAmount:GetText(), "%d+"))
        if player1PPBetAmountValue then
            player1NewPPAmount = player1PPBetAmountValue * colouredPairPayoutReturn
            player1PPBetAmount:SetText(player1NewPPAmount .. " G")
            player1PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player1PlaceBetsPPWin()
    player1PPSideBetWin = true

    player1SessionWin = player1SessionWin + tonumber(player1NewPPAmount)

end

function player1PerfectPairWin(message)

    if playerName == unitName1 then
        player1PPBetAmountValue = tonumber(string.match(player1PPBetEditBox:GetText(), "%d+"))
        if player1PPBetAmountValue then
            player1NewPPAmount = player1PPBetAmountValue * perfectPairPayoutReturn
            player1PPBetAmount:SetText(player1NewPPAmount .. " G")
            player1PPBetAmount:SetTextColor(0, 1, 0)

            player1PPProfitvalue = player1NewPPAmount - player1PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player1totalWin = player1totalWin + tonumber(player1PPProfitvalue)
                    bankingInfo.totalWon = player1totalWin
                    player1totalProfit = player1totalProfit + tonumber(player1PPProfitvalue)
                    bankingInfo.totalProfit = player1totalProfit
                    player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1NewPPAmount)
                    bankingInfo.bankrollTable = player1TotalBankrollAmount
                end

            historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
            historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
            if player1totalProfit >= 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        end
    else
        player1PPBetAmountValue = tonumber(string.match(player1PPBetAmount:GetText(), "%d+"))
        if player1PPBetAmountValue then
            player1NewPPAmount = player1PPBetAmountValue * perfectPairPayoutReturn
            player1PPBetAmount:SetText(player1NewPPAmount .. " G")
            player1PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player1PlaceBetsPPWin()
    player1PPSideBetWin = true

    player1SessionWin = player1SessionWin + tonumber(player1NewPPAmount)

end

function player1SuitedThreeOfAKindWin(message)

    if playerName == unitName1 then
        player1213BetAmountValue = tonumber(string.match(player1213BetEditBox:GetText(), "%d+"))
        if player1213BetAmountValue then
            player1New213Amount = player1213BetAmountValue * suitedThreeOfAKindPayoutReturn
            player1213BetAmount:SetText(player1New213Amount .. " G")
            player1213BetAmount:SetTextColor(0, 1, 0)

            player1213Profitvalue = player1New213Amount - player1213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1totalWin = player1totalWin + tonumber(player1213Profitvalue)
                bankingInfo.totalWon = player1totalWin
                player1totalProfit = player1totalProfit + tonumber(player1213Profitvalue)
                bankingInfo.totalProfit = player1totalProfit
                player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1New213Amount)
                bankingInfo.bankrollTable = player1TotalBankrollAmount
            end

            historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
            historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
            if player1totalProfit >= 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        end
    else
        player1213BetAmountValue = tonumber(string.match(player1213BetAmount:GetText(), "%d+"))
        if player1213BetAmountValue then
            player1New213Amount = player1213BetAmountValue * suitedThreeOfAKindPayoutReturn
            player1213BetAmount:SetText(player1New213Amount .. " G")
            player1213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player1PlaceBets213Win()
    player1213SideBetWin = true

    player1SessionWin = player1SessionWin + tonumber(player1New213Amount)

end

function player1StraightFlushWin(message)

    if playerName == unitName1 then
        player1213BetAmountValue = tonumber(string.match(player1213BetEditBox:GetText(), "%d+"))
        if player1213BetAmountValue then
            player1New213Amount = player1213BetAmountValue * straightFlushPayoutReturn
            player1213BetAmount:SetText(player1New213Amount .. " G")
            player1213BetAmount:SetTextColor(0, 1, 0)

            player1213Profitvalue = player1New213Amount - player1213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1totalWin = player1totalWin + tonumber(player1213Profitvalue)
                bankingInfo.totalWon = player1totalWin
                player1totalProfit = player1totalProfit + tonumber(player1213Profitvalue)
                bankingInfo.totalProfit = player1totalProfit
                player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1New213Amount)
                bankingInfo.bankrollTable = player1TotalBankrollAmount
            end

            historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
            historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
            if player1totalProfit >= 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        end
    else
        player1213BetAmountValue = tonumber(string.match(player1213BetAmount:GetText(), "%d+"))
        if player1213BetAmountValue then
            player1New213Amount = player1213BetAmountValue * straightFlushPayoutReturn
            player1213BetAmount:SetText(player1New213Amount .. " G")
            player1213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player1PlaceBets213Win()
    player1213SideBetWin = true

    player1SessionWin = player1SessionWin + tonumber(player1New213Amount)

end

function player1ThreeOfAKindWin(message)

    if playerName == unitName1 then
        player1213BetAmountValue = tonumber(string.match(player1213BetEditBox:GetText(), "%d+"))
        if player1213BetAmountValue then
            player1New213Amount = player1213BetAmountValue * threeOfAKindPayoutReturn
            player1213BetAmount:SetText(player1New213Amount .. " G")
            player1213BetAmount:SetTextColor(0, 1, 0)

            player1213Profitvalue = player1New213Amount - player1213BetAmountValue


            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1totalWin = player1totalWin + tonumber(player1213Profitvalue)
                bankingInfo.totalWon = player1totalWin
                player1totalProfit = player1totalProfit + tonumber(player1213Profitvalue)
                bankingInfo.totalProfit = player1totalProfit
                player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1New213Amount)
                bankingInfo.bankrollTable = player1TotalBankrollAmount
            end


            historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
            historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
            if player1totalProfit >= 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        end
    else
        player1213BetAmountValue = tonumber(string.match(player1213BetAmount:GetText(), "%d+"))
        if player1213BetAmountValue then
            player1New213Amount = player1213BetAmountValue * threeOfAKindPayoutReturn
            player1213BetAmount:SetText(player1New213Amount .. " G")
            player1213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player1PlaceBets213Win()
    player1213SideBetWin = true

    player1SessionWin = player1SessionWin + tonumber(player1New213Amount)

end

function player1StraightWin(message)

    if playerName == unitName1 then
        player1213BetAmountValue = tonumber(string.match(player1213BetEditBox:GetText(), "%d+"))
        if player1213BetAmountValue then
            player1New213Amount = player1213BetAmountValue * straightPayoutReturn
            player1213BetAmount:SetText(player1New213Amount .. " G")
            player1213BetAmount:SetTextColor(0, 1, 0)

            player1213Profitvalue = player1New213Amount - player1213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1totalWin = player1totalWin + tonumber(player1213Profitvalue)
                bankingInfo.totalWon = player1totalWin
                player1totalProfit = player1totalProfit + tonumber(player1213Profitvalue)
                bankingInfo.totalProfit = player1totalProfit
                player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1New213Amount)
                bankingInfo.bankrollTable = player1TotalBankrollAmount
            end

            historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
            historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
            if player1totalProfit >= 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        end
    else
        player1213BetAmountValue = tonumber(string.match(player1213BetAmount:GetText(), "%d+"))
        if player1213BetAmountValue then
            player1New213Amount = player1213BetAmountValue * straightPayoutReturn
            player1213BetAmount:SetText(player1New213Amount .. " G")
            player1213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player1PlaceBets213Win()
    player1213SideBetWin = true

    player1SessionWin = player1SessionWin + tonumber(player1New213Amount)

end

function player1FlushWin(message)

    if playerName == unitName1 then
        player1213BetAmountValue = tonumber(string.match(player1213BetEditBox:GetText(), "%d+"))
        if player1213BetAmountValue then
            player1New213Amount = player1213BetAmountValue * flushPayoutReturn
            player1213BetAmount:SetText(player1New213Amount .. " G")
            player1213BetAmount:SetTextColor(0, 1, 0)

            player1213Profitvalue = player1New213Amount - player1213BetAmountValue
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player1totalWin = player1totalWin + tonumber(player1213Profitvalue)
                    bankingInfo.totalWon = player1totalWin
                    player1totalProfit = player1totalProfit + tonumber(player1213Profitvalue)
                    bankingInfo.totalProfit = player1totalProfit
                    player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1New213Amount)
                    bankingInfo.bankrollTable = player1TotalBankrollAmount
                end

            historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
            historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
            if player1totalProfit >= 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        end
    else
        player1213BetAmountValue = tonumber(string.match(player1213BetAmount:GetText(), "%d+"))
        if player1213BetAmountValue then
            player1New213Amount = player1213BetAmountValue * flushPayoutReturn
            player1213BetAmount:SetText(player1New213Amount .. " G")
            player1213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player1PlaceBets213Win()
    player1213SideBetWin = true

    player1SessionWin = player1SessionWin + tonumber(player1New213Amount)

end

function player1Loss()
    player1MainBetValue = tonumber(string.match(player1MainBetAmount:GetText(), "%d+"))
    if player1MainBetValue then
        
        if playerName == unitName1 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1totalLoss = player1totalLoss + tonumber(player1MainBetValue)
                bankingInfo.totalLost = player1totalLoss
                player1totalProfit = player1totalProfit - tonumber(player1MainBetValue)
                bankingInfo.totalProfit = player1totalProfit
            end
        end

        if player1totalProfit >= 0 then
            historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

        historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
        historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")

        player1PPBetText = player1PPBetAmount:GetText()

        if player1PPBetText and player1PPBetText ~= "" then
            player1PPBetAmountValue = tonumber(string.match(player1PPBetText, "%d+"))
            
            if player1PPBetAmountValue then
                if player1PPSideBetWin == false then

                    player1PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName1 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player1totalLoss = player1totalLoss + tonumber(player1PPBetAmountValue)
                            bankingInfo.totalLost = player1totalLoss
                            player1totalProfit = player1totalProfit - tonumber(player1PPBetAmountValue)
                            bankingInfo.totalProfit = player1totalProfit
                        end
                    end
            
                    if player1totalProfit >= 0 then
                        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end
            
                    historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")

                end
            end
        end

        player1213BetText = player1213BetAmount:GetText()

        if player1213BetText and player1213BetText ~= "" then
            player1213BetAmountValue = tonumber(string.match(player1213BetText, "%d+"))

            if player1213BetAmountValue then
                if player1213SideBetWin == false then

                    player1213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName1 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player1totalLoss = player1totalLoss + tonumber(player1213BetAmountValue)
                            bankingInfo.totalLost = player1totalLoss
                            player1totalProfit = player1totalProfit - tonumber(player1213BetAmountValue)
                            bankingInfo.totalProfit = player1totalProfit
                        end
                    end
            
                    if player1totalProfit >= 0 then
                        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end
            
                    historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")

                end
            end
        end
    end
end

function player1SplitH1Loss()
    player1SplitHand1BetAmountValue = tonumber(string.match(player1SplitH1BetAmount:GetText(), "%d+"))
    if player1SplitHand1BetAmountValue then

        if playerName == unitName1 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1totalLoss = player1totalLoss + tonumber(player1SplitHand1BetAmountValue)
                bankingInfo.totalLost = player1totalLoss
                player1totalProfit = player1totalProfit - tonumber(player1SplitHand1BetAmountValue)
                bankingInfo.totalProfit = player1totalProfit
            end
        end

        historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
        historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")

        if player1totalProfit >= 0 then
            historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

    end
end

function player1SplitH2Loss()
    player1SplitHand2BetAmountValue = tonumber(string.match(player1SplitH2BetAmount:GetText(), "%d+"))
    if player1SplitHand2BetAmountValue then

        if playerName == unitName1 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1totalLoss = player1totalLoss + tonumber(player1SplitHand2BetAmountValue)
                bankingInfo.totalLost = player1totalLoss
                player1totalProfit = player1totalProfit - tonumber(player1SplitHand2BetAmountValue)
                bankingInfo.totalProfit = player1totalProfit
            end
        end

        historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
        historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")

        if player1totalProfit >= 0 then
            historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

        player1PPBetText = player1PPBetAmount:GetText()

        if player1PPBetText and player1PPBetText ~= "" then
            player1PPBetAmountValue = tonumber(string.match(player1PPBetText, "%d+"))
            
            if player1PPBetAmountValue then
                if player1PPSideBetWin == false then

                    player1PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName1 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player1totalLoss = player1totalLoss + tonumber(player1PPBetAmountValue)
                            bankingInfo.totalLost = player1totalLoss
                            player1totalProfit = player1totalProfit - tonumber(player1PPBetAmountValue)
                            bankingInfo.totalProfit = player1totalProfit
                        end
                    end
            
                    historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
                    if player1totalProfit >= 0 then
                        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player1213BetText = player1213BetAmount:GetText()

        if player1213BetText and player1213BetText ~= "" then
            player1213BetAmountValue = tonumber(string.match(player1213BetText, "%d+"))

            if player1213BetAmountValue then
                if player1213SideBetWin == false then

                    player1213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName1 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player1totalLoss = player1totalLoss + tonumber(player1213BetAmountValue)
                            bankingInfo.totalLost = player1totalLoss
                            player1totalProfit = player1totalProfit - tonumber(player1213BetAmountValue)
                            bankingInfo.totalProfit = player1totalProfit
                        end
                    end
            
                    historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
                    if player1totalProfit >= 0 then
                        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

function player1Push()
    player1MainBetValue = tonumber(string.match(player1MainBetAmount:GetText(), "%d+"))
    if player1MainBetValue then


        if playerName == unitName1 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1MainBetValue)
                bankingInfo.bankrollTable = player1TotalBankrollAmount
            end
        end

        bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

        player1PPBetText = player1PPBetAmount:GetText()

        if player1PPBetText and player1PPBetText ~= "" then
            player1PPBetAmountValue = tonumber(string.match(player1PPBetText, "%d+"))
            
            if player1PPBetAmountValue then
                if player1PPSideBetWin == false then

                    player1PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName1 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player1totalLoss = player1totalLoss + tonumber(player1PPBetAmountValue)
                            bankingInfo.totalLost = player1totalLoss
                            player1totalProfit = player1totalProfit - tonumber(player1PPBetAmountValue)
                            bankingInfo.totalProfit = player1totalProfit
                        end
                    end
            
                    historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
                    if player1totalProfit >= 0 then
                        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player1213BetText = player1213BetAmount:GetText()

        if player1213BetText and player1213BetText ~= "" then
            player1213BetAmountValue = tonumber(string.match(player1213BetText, "%d+"))

            if player1213BetAmountValue then
                if player1213SideBetWin == false then

                    player1213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName1 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player1totalLoss = player1totalLoss + tonumber(player1213BetAmountValue)
                            bankingInfo.totalLost = player1totalLoss
                            player1totalProfit = player1totalProfit - tonumber(player1213BetAmountValue)
                            bankingInfo.totalProfit = player1totalProfit
                        end
                    end
            
                    historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
                    if player1totalProfit >= 0 then
                        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player1SessionWin = player1SessionWin + tonumber(player1MainBetValue)

    end
end

function player1SplitH1Push()
    player1SplitHand1BetAmountValue = tonumber(string.match(player1SplitH1BetAmount:GetText(), "%d+"))
    if player1SplitHand1BetAmountValue then

        if playerName == unitName1 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1SplitHand1BetAmountValue)
                bankingInfo.bankrollTable = player1TotalBankrollAmount
            end
        end

        bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
    
        player1SessionWin = player1SessionWin + tonumber(player1SplitHand1BetAmountValue)
    
    end
end

function player1SplitH2Push()
    player1SplitHand2BetAmountValue = tonumber(string.match(player1SplitH2BetAmount:GetText(), "%d+"))
    if player1SplitHand2BetAmountValue then

        if playerName == unitName1 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1SplitHand2BetAmountValue)
                bankingInfo.bankrollTable = player1TotalBankrollAmount
            end
        end

        bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

        player1PPBetText = player1PPBetAmount:GetText()

        if player1PPBetText and player1PPBetText ~= "" then
            player1PPBetAmountValue = tonumber(string.match(player1PPBetText, "%d+"))
            
            if player1PPBetAmountValue then
                if player1PPSideBetWin == false then

                    player1PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName1 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player1totalLoss = player1totalLoss + tonumber(player1PPBetAmountValue)
                            bankingInfo.totalLost = player1totalLoss
                            player1totalProfit = player1totalProfit - tonumber(player1PPBetAmountValue)
                            bankingInfo.totalProfit = player1totalProfit
                        end
                    end
            
                    historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
                    if player1totalProfit >= 0 then
                        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player1213BetText = player1213BetAmount:GetText()

        if player1213BetText and player1213BetText ~= "" then
            player1213BetAmountValue = tonumber(string.match(player1213BetText, "%d+"))

            if player1213BetAmountValue then
                if player1213SideBetWin == false then

                    player1213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName1 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player1totalLoss = player1totalLoss + tonumber(player1213BetAmountValue)
                            bankingInfo.totalLost = player1totalLoss
                            player1totalProfit = player1totalProfit - tonumber(player1213BetAmountValue)
                            bankingInfo.totalProfit = player1totalProfit
                        end
                    end
            
                    historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
                    if player1totalProfit >= 0 then
                        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    
        player1SessionWin = player1SessionWin + tonumber(player1SplitHand2BetAmountValue)
    
    end
end

function player1BJWin(message)
    player1MainBetAmountValue = tonumber(string.match(player1MainBetAmount:GetText(), "%d+"))
    if player1MainBetAmountValue then
        player1BJWinAmountValue = player1MainBetAmountValue * 2.5
        player1MainBetAmount:SetText(player1BJWinAmountValue .. " G")
    end

    player1BJProfitvalue = player1BJWinAmountValue - player1MainBetAmountValue

    if playerName == unitName1 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player1totalWin = player1totalWin + tonumber(player1BJProfitvalue)
            bankingInfo.totalWon = player1totalWin
            player1totalProfit = player1totalProfit + tonumber(player1BJProfitvalue)
            bankingInfo.totalProfit = player1totalProfit
            player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1BJWinAmountValue)
            bankingInfo.bankrollTable = player1TotalBankrollAmount
        end
    end

    if player1totalProfit >= 0 then
        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
    bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
    cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

    player1PPBetText = player1PPBetAmount:GetText()

    if player1PPBetText and player1PPBetText ~= "" then
        player1PPBetAmountValue = tonumber(string.match(player1PPBetText, "%d+"))
        
        if player1PPBetAmountValue then
            if player1PPSideBetWin == false then

                player1PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName1 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player1totalLoss = player1totalLoss + tonumber(player1PPBetAmountValue)
                        bankingInfo.totalLost = player1totalLoss
                        player1totalProfit = player1totalProfit - tonumber(player1PPBetAmountValue)
                        bankingInfo.totalProfit = player1totalProfit
                    end
                end
        
                historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
        
                if player1totalProfit >= 0 then
                    historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player1213BetText = player1213BetAmount:GetText()

    if player1213BetText and player1213BetText ~= "" then
        player1213BetAmountValue = tonumber(string.match(player1213BetText, "%d+"))

        if player1213BetAmountValue then
            if player1213SideBetWin == false then

                player1213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName1 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player1totalLoss = player1totalLoss + tonumber(player1213BetAmountValue)
                        bankingInfo.totalLost = player1totalLoss
                        player1totalProfit = player1totalProfit - tonumber(player1213BetAmountValue)
                        bankingInfo.totalProfit = player1totalProfit
                    end
                end
        
                historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
        
                if player1totalProfit >= 0 then
                    historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player1MainBetCoins:Hide()
    playerFrame.player1BJWinCoins:Show()

    player1SessionWin = player1SessionWin + tonumber(player1BJWinAmountValue)

end

function player1SplitH1BJ(message)
    player1SplitHand1BetAmountValue = tonumber(string.match(player1SplitH1BetAmount:GetText(), "%d+"))
    if player1SplitHand1BetAmountValue then
        player1SplitHand1BJWinAmountValue = player1SplitHand1BetAmountValue * 2.5
        player1SplitH1BetAmount:SetText(player1SplitHand1BJWinAmountValue .. " G")
    end

    player1SplitHand1BJProfitValue = player1SplitHand1BJWinAmountValue - player1SplitHand1BetAmountValue

    if playerName == unitName1 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player1totalWin = player1totalWin + tonumber(player1SplitHand1BJProfitValue)
            bankingInfo.totalWon = player1totalWin
            player1totalProfit = player1totalProfit + tonumber(player1SplitHand1BJProfitValue)
            bankingInfo.totalProfit = player1totalProfit
            player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1SplitHand1BJWinAmountValue)
            bankingInfo.bankrollTable = player1TotalBankrollAmount
        end
    end

    if player1totalProfit >= 0 then
        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
    bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
    cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

    playerFrame.player1SplitHand1Coins:Hide()
    playerFrame.player1SplitHand1BJWinCoins:Show()

    player1SessionWin = player1SessionWin + tonumber(player1SplitHand1BJWinAmountValue)

end

function player1SplitH2BJ(message)
    player1SplitHand2BetAmountValue = tonumber(string.match(player1SplitH2BetAmount:GetText(), "%d+"))
    if player1SplitHand2BetAmountValue then
        player1SplitHand2BJWinAmountValue = player1SplitHand2BetAmountValue * 2.5
        player1SplitH2BetAmount:SetText(player1SplitHand2BJWinAmountValue .. " G")
    end

    player1SplitHand2BJProfitValue = player1SplitHand2BJWinAmountValue - player1SplitHand2BetAmountValue

    if playerName == unitName1 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player1totalWin = player1totalWin + tonumber(player1SplitHand2BJProfitValue)
            bankingInfo.totalWon = player1totalWin
            player1totalProfit = player1totalProfit + tonumber(player1SplitHand2BJProfitValue)
            bankingInfo.totalProfit = player1totalProfit
            player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1SplitHand2BJWinAmountValue)
            bankingInfo.bankrollTable = player1TotalBankrollAmount
        end
    end

    if player1totalProfit >= 0 then
        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
    bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
    cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

    player1PPBetText = player1PPBetAmount:GetText()

    if player1PPBetText and player1PPBetText ~= "" then
        player1PPBetAmountValue = tonumber(string.match(player1PPBetText, "%d+"))
        
        if player1PPBetAmountValue then
            if player1PPSideBetWin == false then

                player1PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName1 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player1totalLoss = player1totalLoss + tonumber(player1PPBetAmountValue)
                        bankingInfo.totalLost = player1totalLoss
                        player1totalProfit = player1totalProfit - tonumber(player1PPBetAmountValue)
                        bankingInfo.totalProfit = player1totalProfit
                    end
                end
        
                historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
        
                if player1totalProfit >= 0 then
                    historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player1213BetText = player1213BetAmount:GetText()

    if player1213BetText and player1213BetText ~= "" then
        player1213BetAmountValue = tonumber(string.match(player1213BetText, "%d+"))

        if player1213BetAmountValue then
            if player1213SideBetWin == false then

                player1213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName1 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player1totalLoss = player1totalLoss + tonumber(player1213BetAmountValue)
                        bankingInfo.totalLost = player1totalLoss
                        player1totalProfit = player1totalProfit - tonumber(player1213BetAmountValue)
                        bankingInfo.totalProfit = player1totalProfit
                    end
                end
        
                historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
        
                if player1totalProfit >= 0 then
                    historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player1SplitHand2Coins:Hide()
    playerFrame.player1SplitHand2BJWinCoins:Show()

    player1SessionWin = player1SessionWin + tonumber(player1SplitHand2BJWinAmountValue)

end

function player1Win(message)
    player1MainBetAmountValue = tonumber(string.match(player1MainBetAmount:GetText(), "%d+"))
    if player1MainBetAmountValue then
        player1NormalWinAmountValue = player1MainBetAmountValue * 2
        player1MainBetAmount:SetText(player1NormalWinAmountValue .. " G")

        if playerName == unitName1 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player1totalWin = player1totalWin + tonumber(player1MainBetAmountValue)
                bankingInfo.totalWon = player1totalWin
                player1totalProfit = player1totalProfit + tonumber(player1MainBetAmountValue)
                bankingInfo.totalProfit = player1totalProfit
                player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1NormalWinAmountValue)
                bankingInfo.bankrollTable = player1TotalBankrollAmount
            end
        end
    
        if player1totalProfit >= 0 then
            historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end
    
        historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
        historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
        bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

        player1PPBetText = player1PPBetAmount:GetText()

        if player1PPBetText and player1PPBetText ~= "" then
            player1PPBetAmountValue = tonumber(string.match(player1PPBetText, "%d+"))
            
            if player1PPBetAmountValue then
                if player1PPSideBetWin == false then

                    player1PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName1 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player1totalLoss = player1totalLoss + tonumber(player1PPBetAmountValue)
                            bankingInfo.totalLost = player1totalLoss
                            player1totalProfit = player1totalProfit - tonumber(player1PPBetAmountValue)
                            bankingInfo.totalProfit = player1totalProfit
                        end
                    end
            
                    historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
                    if player1totalProfit >= 0 then
                        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player1213BetText = player1213BetAmount:GetText()

        if player1213BetText and player1213BetText ~= "" then
            player1213BetAmountValue = tonumber(string.match(player1213BetText, "%d+"))

            if player1213BetAmountValue then
                if player1213SideBetWin == false then

                    player1213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName1 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player1totalLoss = player1totalLoss + tonumber(player1213BetAmountValue)
                            bankingInfo.totalLost = player1totalLoss
                            player1totalProfit = player1totalProfit - tonumber(player1213BetAmountValue)
                            bankingInfo.totalProfit = player1totalProfit
                        end
                    end
            
                    historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            
                    if player1totalProfit >= 0 then
                        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end

    playerFrame.player1MainBetCoins:Hide()
    playerFrame.player1NormalWinCoins:Show()

    player1SessionWin = player1SessionWin + tonumber(player1NormalWinAmountValue)

end

function player1SplitH1Win(message)
    player1SplitHand1BetAmountValue = tonumber(string.match(player1SplitH1BetAmount:GetText(), "%d+"))
    if player1SplitHand1BetAmountValue then
        player1SplitHand1NormalWinAmountValue = player1SplitHand1BetAmountValue * 2
        player1SplitH1BetAmount:SetText(player1SplitHand1NormalWinAmountValue .. " G")
    end

    if playerName == unitName1 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player1totalWin = player1totalWin + tonumber(player1SplitHand1BetAmountValue)
            bankingInfo.totalWon = player1totalWin
            player1totalProfit = player1totalProfit + tonumber(player1SplitHand1BetAmountValue)
            bankingInfo.totalProfit = player1totalProfit
            player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1SplitHand1NormalWinAmountValue)
            bankingInfo.bankrollTable = player1TotalBankrollAmount
        end
    end

    if player1totalProfit >= 0 then
        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
    bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
    cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

    playerFrame.player1SplitHand1Coins:Hide()
    playerFrame.player1SplitHand1NormalWinCoins:Show()

    player1SessionWin = player1SessionWin + tonumber(player1SplitHand1NormalWinAmountValue)

end

function player1SplitH2Win(message)
    player1SplitHand2BetAmountValue = tonumber(string.match(player1SplitH2BetAmount:GetText(), "%d+"))
    if player1SplitHand2BetAmountValue then
        player1SplitHand2NormalWinAmountValue = player1SplitHand2BetAmountValue * 2
        player1SplitH2BetAmount:SetText(player1SplitHand2NormalWinAmountValue .. " G")
    end

    if playerName == unitName1 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player1totalWin = player1totalWin + tonumber(player1SplitHand2BetAmountValue)
            bankingInfo.totalWon = player1totalWin
            player1totalProfit = player1totalProfit + tonumber(player1SplitHand2BetAmountValue)
            bankingInfo.totalProfit = player1totalProfit
            player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1SplitHand2NormalWinAmountValue)
            bankingInfo.bankrollTable = player1TotalBankrollAmount
        end
    end

    if player1totalProfit >= 0 then
        historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
    historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
    bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
    cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

    player1PPBetText = player1PPBetAmount:GetText()

    if player1PPBetText and player1PPBetText ~= "" then
        player1PPBetAmountValue = tonumber(string.match(player1PPBetText, "%d+"))
        
        if player1PPBetAmountValue then
            if player1PPSideBetWin == false then

                player1PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName1 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player1totalLoss = player1totalLoss + tonumber(player1PPBetAmountValue)
                        bankingInfo.totalLost = player1totalLoss
                        player1totalProfit = player1totalProfit - tonumber(player1PPBetAmountValue)
                        bankingInfo.totalProfit = player1totalProfit
                    end
                end
        
                historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
        
                if player1totalProfit >= 0 then
                    historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player1213BetText = player1213BetAmount:GetText()

    if player1213BetText and player1213BetText ~= "" then
        player1213BetAmountValue = tonumber(string.match(player1213BetText, "%d+"))

        if player1213BetAmountValue then
            if player1213SideBetWin == false then

                player1213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName1 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player1totalLoss = player1totalLoss + tonumber(player1213BetAmountValue)
                        bankingInfo.totalLost = player1totalLoss
                        player1totalProfit = player1totalProfit - tonumber(player1213BetAmountValue)
                        bankingInfo.totalProfit = player1totalProfit
                    end
                end
        
                historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
                historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
        
                if player1totalProfit >= 0 then
                    historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player1SplitHand2Coins:Hide()
    playerFrame.player1SplitHand2NormalWinCoins:Show()

    player1SessionWin = player1SessionWin + tonumber(player1SplitHand2NormalWinAmountValue)

end

function player1InsuranceWin(message)

    player1InsuranceBetText = playerFrame.player1InsuranceBetAmount:GetText()

    if player1InsuranceBetText and player1InsuranceBetText ~= "" then
        player1InsuranceBetAmountValue = tonumber(string.match(player1InsuranceBetText, "%d+"))

        if player1InsuranceBetAmountValue then
            player1InsuranceWinAmountValue = player1InsuranceBetAmountValue * 3

            player1InsuranceProfitValue = player1InsuranceWinAmountValue - player1InsuranceBetAmountValue


            if playerName == unitName1 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player1totalWin = player1totalWin + tonumber(player1InsuranceProfitValue)
                    bankingInfo.totalWon = player1totalWin
                    player1totalProfit = player1totalProfit + tonumber(player1InsuranceProfitValue)
                    bankingInfo.totalProfit = player1totalProfit
                    player1TotalBankrollAmount = player1TotalBankrollAmount + tonumber(player1InsuranceWinAmountValue)
                    bankingInfo.bankrollTable = player1TotalBankrollAmount
                end
            end
        
            if player1totalProfit >= 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
        
            historyFrame.player1totalWonAmount:SetText(player1totalWin .. " G")
            historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")
            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")

            player1SessionWin = player1SessionWin + tonumber(player1InsuranceWinAmountValue)

        end
    end
end

function player1InsuranceLoss(message)

    player1InsuranceBetText = playerFrame.player1InsuranceBetAmount:GetText()

    if player1InsuranceBetText and player1InsuranceBetText ~= "" then
        player1InsuranceBetAmountValue = tonumber(string.match(player1InsuranceBetText, "%d+"))

        if player1InsuranceBetAmountValue then

            if playerName == unitName1 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player1totalLoss = player1totalLoss + tonumber(player1InsuranceBetAmountValue)
                    bankingInfo.totalLost = player1totalLoss
                    player1totalProfit = player1totalProfit - tonumber(player1InsuranceBetAmountValue)
                    bankingInfo.totalProfit = player1totalProfit
                end
            end
    
            if player1totalProfit >= 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
    
            historyFrame.player1totalLostAmount:SetText(player1totalLoss .. " G")
            historyFrame.player1ProfitAmount:SetText(player1totalProfit .. " G")

        end
    end
end

function player1SessionWinAnnouncement()
    if playerName == unitName1 then
        if player1SessionWinCalled == false then
            if player1SessionWin >= 50 then
                chatFrame = SELECTED_DOCK_FRAME
                ChatFrame_OpenChat("/me", chatFrame)
                
                editBox = _G[chatFrame:GetName().."EditBox"]
                editBox:SetText("")
                editBox:Insert("/me has won " .. player1SessionWin .. "g from a hand of Blackjack.")
                
                ChatEdit_SendText(editBox)
                ChatEdit_DeactivateChat(editBox)

                UpdateWinningsDisplay(playerFrame.player1WinningsUpdate, player1SessionWin)
                player1resetRaidChannel()
                
            else
                print("")
            end

            player1SessionWinCalled = true
        end
    end
end




















-- >>> PLAYER 2 <<<
-- >>> PLAYER 2 <<<
-- >>> PLAYER 2 <<<

playerFrame.player2CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", 210, 230)
playerFrame.player2CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 28, "OUTLINE") -- Adjust the font and size as needed
playerFrame.player2CardTotalText:SetText("")

playerFrame.player2SplitHand1CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2SplitHand1CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", 247, 247)
playerFrame.player2SplitHand1CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
playerFrame.player2SplitHand1CardTotalText:SetText("")

playerFrame.player2SplitHand2CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2SplitHand2CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", 187, 224)
playerFrame.player2SplitHand2CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
playerFrame.player2SplitHand2CardTotalText:SetText("")

-- Buttons for Player 2
-- Hit
playerFrame.player2HitButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2HitButton:SetPoint("BOTTOM", playerFrame, 222, 127)
playerFrame.player2HitButton:SetSize(65, 30)
playerFrame.player2HitButton:SetText("Hit")
playerFrame.player2HitButton:Disable()
playerFrame.player2HitButton:Hide()
-- Stand
playerFrame.player2StandButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2StandButton:SetPoint("BOTTOM", playerFrame, 288, 127)
playerFrame.player2StandButton:SetSize(65, 30)
playerFrame.player2StandButton:SetText("Stand")
playerFrame.player2StandButton:Disable()
playerFrame.player2StandButton:Hide()
-- Double
playerFrame.player2DoubleButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2DoubleButton:SetPoint("BOTTOM", playerFrame, 222, 97)
playerFrame.player2DoubleButton:SetSize(65, 30)
playerFrame.player2DoubleButton:SetText("Double")
playerFrame.player2DoubleButton:Disable()
playerFrame.player2DoubleButton:Hide()
-- Split
playerFrame.player2SplitButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2SplitButton:SetPoint("BOTTOM", playerFrame, 288, 97)
playerFrame.player2SplitButton:SetSize(65, 30)
playerFrame.player2SplitButton:SetText("Split")
playerFrame.player2SplitButton:Disable()
playerFrame.player2SplitButton:Hide()
-- Insurance Yes
playerFrame.player2InsuranceYesButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2InsuranceYesButton:SetPoint("BOTTOM", playerFrame, 190, 67)
playerFrame.player2InsuranceYesButton:SetSize(55, 30)
playerFrame.player2InsuranceYesButton:SetText("Yes")
playerFrame.player2InsuranceYesButton:Disable()
playerFrame.player2InsuranceYesButton:Hide()
-- Insurance No
playerFrame.player2InsuranceNoButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2InsuranceNoButton:SetPoint("BOTTOM", playerFrame, 318, 67)
playerFrame.player2InsuranceNoButton:SetSize(55, 30)
playerFrame.player2InsuranceNoButton:SetText("No")
playerFrame.player2InsuranceNoButton:Disable()
playerFrame.player2InsuranceNoButton:Hide()
-- Deal Now
playerFrame.player2DealNowButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2DealNowButton:SetPoint("BOTTOM", playerFrame, 255, 67)
playerFrame.player2DealNowButton:SetSize(85, 30)
playerFrame.player2DealNowButton:SetText("Deal Now")
playerFrame.player2DealNowButton:Disable()
playerFrame.player2DealNowButton:Hide()
-- Hit (Split H1)
playerFrame.player2HitButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2HitButtonSplitH1:SetPoint("BOTTOM", playerFrame, 288, 127)
playerFrame.player2HitButtonSplitH1:SetSize(65, 30)
playerFrame.player2HitButtonSplitH1:SetText("Hit")
playerFrame.player2HitButtonSplitH1:Disable()
playerFrame.player2HitButtonSplitH1:Hide()
-- Stand (Split H1)
playerFrame.player2StandButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2StandButtonSplitH1:SetPoint("BOTTOM", playerFrame, 288, 97)
playerFrame.player2StandButtonSplitH1:SetSize(65, 30)
playerFrame.player2StandButtonSplitH1:SetText("Stand")
playerFrame.player2StandButtonSplitH1:Disable()
playerFrame.player2StandButtonSplitH1:Hide()
-- Double (Split H1)
playerFrame.player2DoubleButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2DoubleButtonSplitH1:SetPoint("BOTTOM", playerFrame, 288, 67)
playerFrame.player2DoubleButtonSplitH1:SetSize(65, 30)
playerFrame.player2DoubleButtonSplitH1:SetText("Double")
playerFrame.player2DoubleButtonSplitH1:Disable()
playerFrame.player2DoubleButtonSplitH1:Hide()
-- Hit (Split H2)
playerFrame.player2HitButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2HitButtonSplitH2:SetPoint("BOTTOM", playerFrame, 222, 127)
playerFrame.player2HitButtonSplitH2:SetSize(65, 30)
playerFrame.player2HitButtonSplitH2:SetText("Hit")
playerFrame.player2HitButtonSplitH2:Disable()
playerFrame.player2HitButtonSplitH2:Hide()
-- Stand (Split H2)
playerFrame.player2StandButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2StandButtonSplitH2:SetPoint("BOTTOM", playerFrame, 222, 97)
playerFrame.player2StandButtonSplitH2:SetSize(65, 30)
playerFrame.player2StandButtonSplitH2:SetText("Stand")
playerFrame.player2StandButtonSplitH2:Disable()
playerFrame.player2StandButtonSplitH2:Hide()
-- Double (Split H2)
playerFrame.player2DoubleButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player2DoubleButtonSplitH2:SetPoint("BOTTOM", playerFrame, 222, 67)
playerFrame.player2DoubleButtonSplitH2:SetSize(65, 30)
playerFrame.player2DoubleButtonSplitH2:SetText("Double")
playerFrame.player2DoubleButtonSplitH2:Disable()
playerFrame.player2DoubleButtonSplitH2:Hide()
-- Main Bet Confirm
player2ConfirmMainBetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player2ConfirmMainBetButton:SetPoint("BOTTOM", playerFrame, 288, 187)
player2ConfirmMainBetButton:SetSize(65, 30)
player2ConfirmMainBetButton:SetText("Bet")
player2ConfirmMainBetButton:Hide()
-- Perfect Pairs Confirm
player2ConfirmPPBetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player2ConfirmPPBetButton:SetPoint("BOTTOM", playerFrame, 129, 244)
player2ConfirmPPBetButton:SetSize(43, 25)
player2ConfirmPPBetButton:SetText("Bet")
player2ConfirmPPBetButton:Hide()
-- 21+3 Confirm
player2Confirm213BetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player2Confirm213BetButton:SetPoint("BOTTOM", playerFrame, 245, 295)
player2Confirm213BetButton:SetSize(43, 25)
player2Confirm213BetButton:SetText("Bet")
player2Confirm213BetButton:Hide()

-- Wagers for Player 2
-- Main Bet
player2MainBetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player2MainBetEditBox:SetSize(55, 30)
player2MainBetEditBox:SetPoint("BOTTOM", playerFrame, 225, 187)
player2MainBetEditBox:SetAutoFocus(false)
player2MainBetEditBox:SetNumeric(true)
player2MainBetEditBox:Hide()
-- Split Hand 1
player2SplitH1EditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player2SplitH1EditBox:SetSize(55, 30)
player2SplitH1EditBox:SetPoint("BOTTOM", playerFrame, 290, 187)
player2SplitH1EditBox:SetAutoFocus(false)
player2SplitH1EditBox:SetNumeric(true)
player2SplitH1EditBox:ClearFocus()
player2SplitH1EditBox:Disable()
player2SplitH1EditBox:Hide()
-- Split Hand 2
player2SplitH2EditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player2SplitH2EditBox:SetSize(55, 30)
player2SplitH2EditBox:SetPoint("BOTTOM", playerFrame, 225, 187)
player2SplitH2EditBox:SetAutoFocus(false)
player2SplitH2EditBox:SetNumeric(true)
player2SplitH2EditBox:ClearFocus()
player2SplitH2EditBox:Disable()
player2SplitH2EditBox:Hide()
-- Perfect Pairs
player2PPBetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player2PPBetEditBox:SetSize(35, 30)
player2PPBetEditBox:SetPoint("BOTTOM", playerFrame, 132, 264)
player2PPBetEditBox:SetAutoFocus(false)
player2PPBetEditBox:SetNumeric(true)
player2PPBetEditBox:Hide()
-- 21+3
player2213BetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player2213BetEditBox:SetSize(35, 30)
player2213BetEditBox:SetPoint("BOTTOM", playerFrame, 247, 315)
player2213BetEditBox:SetAutoFocus(false)
player2213BetEditBox:SetNumeric(true)
player2213BetEditBox:Hide()

-- Labels for Player 2
-- Main Bet
playerFrame.player2MainBetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2MainBetTitle:SetPoint("BOTTOM", playerFrame, 224, 214)
playerFrame.player2MainBetTitle:SetJustifyH("CENTER")
playerFrame.player2MainBetTitle:SetText("Main Bet")
playerFrame.player2MainBetTitle:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player2MainBetTitle:Hide()
-- Split Hand 1
playerFrame.player2SplitH1Title = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2SplitH1Title:SetPoint("BOTTOM", playerFrame, 289, 214)
playerFrame.player2SplitH1Title:SetJustifyH("CENTER")
playerFrame.player2SplitH1Title:SetText("Hand 1")
playerFrame.player2SplitH1Title:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player2SplitH1Title:Hide()
-- Split Hand 2
playerFrame.player2SplitH2Title = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2SplitH2Title:SetPoint("BOTTOM", playerFrame, 224, 214)
playerFrame.player2SplitH2Title:SetJustifyH("CENTER")
playerFrame.player2SplitH2Title:SetText("Hand 2")
playerFrame.player2SplitH2Title:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player2SplitH2Title:Hide()
-- Main Bet Amount
player2MainBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2MainBetAmount:SetPoint("CENTER", playerFrame, 189, -16)
player2MainBetAmount:SetJustifyH("CENTER")
player2MainBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Split Hand 1 Amount
player2SplitH1BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2SplitH1BetAmount:SetPoint("CENTER", playerFrame, 203, -9)
player2SplitH1BetAmount:SetJustifyH("CENTER")
player2SplitH1BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Split Hand 2 Amount
player2SplitH2BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2SplitH2BetAmount:SetPoint("CENTER", playerFrame, 174, -24)
player2SplitH2BetAmount:SetJustifyH("CENTER")
player2SplitH2BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Perfect Pairs
playerFrame.player2PPBetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2PPBetTitle:SetPoint("BOTTOM", playerFrame, 96, 262)
playerFrame.player2PPBetTitle:SetJustifyH("CENTER")
playerFrame.player2PPBetTitle:SetText("PP")
playerFrame.player2PPBetTitle:SetFont("Fonts\\FRIZQT__.TTF", 15, "OUTLINE")
playerFrame.player2PPBetTitle:Hide()
-- Perfect Pairs Amount
player2PPBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2PPBetAmount:SetPoint("CENTER", playerFrame, 123, -23)
player2PPBetAmount:SetJustifyH("CENTER")
player2PPBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- 21+3
playerFrame.player2213BetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2213BetTitle:SetPoint("BOTTOM", playerFrame, 290, 312)
playerFrame.player2213BetTitle:SetJustifyH("CENTER")
playerFrame.player2213BetTitle:SetText("21+3")
playerFrame.player2213BetTitle:SetFont("Fonts\\FRIZQT__.TTF", 15, "OUTLINE")
playerFrame.player2213BetTitle:Hide()
-- 21+3 Amount
player2213BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2213BetAmount:SetPoint("CENTER", playerFrame, 231, 29)
player2213BetAmount:SetJustifyH("CENTER")
player2213BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Insurance Amount
playerFrame.player2InsuranceBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2InsuranceBetAmount:SetPoint("CENTER", playerFrame, 364, -258)
playerFrame.player2InsuranceBetAmount:SetJustifyH("CENTER")
playerFrame.player2InsuranceBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
-- Player Name
playerFrame.player2Name = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2Name:SetPoint("BOTTOM", playerFrame, 255, 163)
playerFrame.player2Name:SetText("Seat Empty")
playerFrame.player2Name:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
-- Insurance Bet
playerFrame.player2InsuranceTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2InsuranceTitle:SetPoint("BOTTOM", playerFrame, 255, 81)
playerFrame.player2InsuranceTitle:SetText("Insurance")
playerFrame.player2InsuranceTitle:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
playerFrame.player2InsuranceTitle:Hide()
-- Insurance (if available)
playerFrame.player2InsuranceSubtitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2InsuranceSubtitle:SetPoint("BOTTOM", playerFrame, 255, 71)
playerFrame.player2InsuranceSubtitle:SetText("(if available)")
playerFrame.player2InsuranceSubtitle:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player2InsuranceSubtitle:Hide()
-- Session Win Update
playerFrame.player2WinningsUpdate = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player2WinningsUpdate:SetPoint("BOTTOMLEFT", playerFrame, 270, 30) 
playerFrame.player2WinningsUpdate:SetText("")
playerFrame.player2WinningsUpdate:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
playerFrame.player2WinningsUpdate:SetTextColor(0.118, 0.839, 0.412)

-- Images for Player 2
-- Turn Arrow
playerFrame.player2TurnArrow = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2TurnArrow:SetSize(128, 128)
playerFrame.player2TurnArrow:SetPoint("CENTER", playerFrame, 362, -165)
playerFrame.player2TurnArrow:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\TurnArrow.tga")
playerFrame.player2TurnArrow:SetBlendMode("BLEND")
playerFrame.player2TurnArrow:SetDrawLayer("OVERLAY")
playerFrame.player2TurnArrow:Hide()
-- Main Bet
playerFrame.player2MainBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2MainBetCoins:SetSize(128, 128)
playerFrame.player2MainBetCoins:SetPoint("CENTER", playerFrame, 206, -47)
playerFrame.player2MainBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player2MainBetCoins:SetBlendMode("BLEND")
playerFrame.player2MainBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player2MainBetCoins:Hide()
-- Win
playerFrame.player2NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2NormalWinCoins:SetSize(128, 128)
playerFrame.player2NormalWinCoins:SetPoint("CENTER", playerFrame, 206, -47)
playerFrame.player2NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player2NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player2NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player2NormalWinCoins:Hide()
-- Split Hand 2 Bet
playerFrame.player2SplitHand2Coins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2SplitHand2Coins:SetSize(128, 128)
playerFrame.player2SplitHand2Coins:SetPoint("CENTER", playerFrame, 190, -55)
playerFrame.player2SplitHand2Coins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player2SplitHand2Coins:SetBlendMode("BLEND")
playerFrame.player2SplitHand2Coins:SetDrawLayer("OVERLAY")
playerFrame.player2SplitHand2Coins:Hide()
-- Split Double Hand 2 Bet
playerFrame.player2SplitHand2DoubleCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2SplitHand2DoubleCoins:SetSize(128, 128)
playerFrame.player2SplitHand2DoubleCoins:SetPoint("CENTER", playerFrame, 196, -59)
playerFrame.player2SplitHand2DoubleCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player2SplitHand2DoubleCoins:SetBlendMode("BLEND")
playerFrame.player2SplitHand2DoubleCoins:SetDrawLayer("OVERLAY")
playerFrame.player2SplitHand2DoubleCoins:Hide()
-- Split Win Hand 2
playerFrame.player2SplitHand2NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2SplitHand2NormalWinCoins:SetSize(128, 128)
playerFrame.player2SplitHand2NormalWinCoins:SetPoint("CENTER", playerFrame, 196, -59)
playerFrame.player2SplitHand2NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player2SplitHand2NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player2SplitHand2NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player2SplitHand2NormalWinCoins:Hide()
-- Split Hand 1 Bet
playerFrame.player2SplitHand1Coins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2SplitHand1Coins:SetSize(128, 128)
playerFrame.player2SplitHand1Coins:SetPoint("CENTER", playerFrame, 220, -40)
playerFrame.player2SplitHand1Coins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player2SplitHand1Coins:SetBlendMode("BLEND")
playerFrame.player2SplitHand1Coins:SetDrawLayer("OVERLAY")
playerFrame.player2SplitHand1Coins:Hide()
-- Split Double Hand 1 Bet
playerFrame.player2SplitHand1DoubleCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2SplitHand1DoubleCoins:SetSize(128, 128)
playerFrame.player2SplitHand1DoubleCoins:SetPoint("CENTER", playerFrame, 223, -34)
playerFrame.player2SplitHand1DoubleCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player2SplitHand1DoubleCoins:SetBlendMode("BLEND")
playerFrame.player2SplitHand1DoubleCoins:SetDrawLayer("OVERLAY")
playerFrame.player2SplitHand1DoubleCoins:Hide()
-- Split Win Hand 1
playerFrame.player2SplitHand1NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2SplitHand1NormalWinCoins:SetSize(128, 128)
playerFrame.player2SplitHand1NormalWinCoins:SetPoint("CENTER", playerFrame, 223, -34)
playerFrame.player2SplitHand1NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player2SplitHand1NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player2SplitHand1NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player2SplitHand1NormalWinCoins:Hide()
-- Blackjack Win
playerFrame.player2BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2BJWinCoins:SetSize(128, 128)
playerFrame.player2BJWinCoins:SetPoint("CENTER", playerFrame, 206, -47)
playerFrame.player2BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player2BJWinCoins:SetBlendMode("BLEND")
playerFrame.player2BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player2BJWinCoins:Hide()
-- Split BJ Win Hand 2
playerFrame.player2SplitHand2BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2SplitHand2BJWinCoins:SetSize(128, 128)
playerFrame.player2SplitHand2BJWinCoins:SetPoint("CENTER", playerFrame, 196, -59)
playerFrame.player2SplitHand2BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player2SplitHand2BJWinCoins:SetBlendMode("BLEND")
playerFrame.player2SplitHand2BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player2SplitHand2BJWinCoins:Hide()
-- Split BJ Win Hand 1
playerFrame.player2SplitHand1BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2SplitHand1BJWinCoins:SetSize(128, 128)
playerFrame.player2SplitHand1BJWinCoins:SetPoint("CENTER", playerFrame, 223, -34)
playerFrame.player2SplitHand1BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player2SplitHand1BJWinCoins:SetBlendMode("BLEND")
playerFrame.player2SplitHand1BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player2SplitHand1BJWinCoins:Hide()
-- Double Bet
playerFrame.player2DoubleBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2DoubleBetCoins:SetSize(128, 128)
playerFrame.player2DoubleBetCoins:SetPoint("CENTER", playerFrame, 206, -47)
playerFrame.player2DoubleBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player2DoubleBetCoins:SetBlendMode("BLEND")
playerFrame.player2DoubleBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player2DoubleBetCoins:Hide()
-- PP Bet
playerFrame.player2PPBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2PPBetCoins:SetSize(128, 128)
playerFrame.player2PPBetCoins:SetPoint("CENTER", playerFrame, 127, -42)
playerFrame.player2PPBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsHalfBet.tga")
playerFrame.player2PPBetCoins:SetBlendMode("BLEND")
playerFrame.player2PPBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player2PPBetCoins:Hide()
-- 21+3 Bet
playerFrame.player2213BetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2213BetCoins:SetSize(128, 128)
playerFrame.player2213BetCoins:SetPoint("CENTER", playerFrame, 235, 8)
playerFrame.player2213BetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsHalfBet.tga")
playerFrame.player2213BetCoins:SetBlendMode("BLEND")
playerFrame.player2213BetCoins:SetDrawLayer("OVERLAY")
playerFrame.player2213BetCoins:Hide()
-- PP Win
playerFrame.player2PPWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2PPWinCoins:SetSize(128, 128)
playerFrame.player2PPWinCoins:SetPoint("CENTER", playerFrame, 138, -36)
playerFrame.player2PPWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player2PPWinCoins:SetBlendMode("BLEND")
playerFrame.player2PPWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player2PPWinCoins:Hide()
-- 21+3 Win
playerFrame.player2213WinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player2213WinCoins:SetSize(128, 128)
playerFrame.player2213WinCoins:SetPoint("CENTER", playerFrame, 246, 16)
playerFrame.player2213WinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player2213WinCoins:SetBlendMode("BLEND")
playerFrame.player2213WinCoins:SetDrawLayer("OVERLAY")
playerFrame.player2213WinCoins:Hide()
-- Insurance YES for Player 2
player2InsuranceYesIcon = playerFrame:CreateTexture(nil, "OVERLAY")
player2InsuranceYesIcon:SetSize(24, 24)
player2InsuranceYesIcon:SetPoint("CENTER", playerFrame, 361, -278)
player2InsuranceYesIcon:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\insuranceYes.tga")
player2InsuranceYesIcon:SetDrawLayer("OVERLAY")
player2InsuranceYesIcon:Hide()
-- Insurance NO for Player 2
player2InsuranceNoIcon = playerFrame:CreateTexture(nil, "OVERLAY")
player2InsuranceNoIcon:SetSize(24, 24)
player2InsuranceNoIcon:SetPoint("CENTER", playerFrame, 361, -278)
player2InsuranceNoIcon:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\insuranceNo.tga")
player2InsuranceNoIcon:SetDrawLayer("OVERLAY")
player2InsuranceNoIcon:Hide()

-- BJ Win Coins
function player2PlaceCoinsBJWin(message)
    playerFrame.player2MainBetCoins:Hide()
    playerFrame.player2BJWinCoins:Show()
end

-- Regular Win Coins
function player2PlaceCoinsRegularWin(message)
    playerFrame.player2MainBetCoins:Hide()
    playerFrame.player2DoubleBetCoins:Show()
end

-- Main Bet Coins
function player2PlaceCoinsMainBet(message)
    playerFrame.player2MainBetCoins:Show()
end

-- Double Bet Coins
function player2PlaceCoinsDoubleBet(message)
    playerFrame.player2MainBetCoins:Hide()
    playerFrame.player2DoubleBetCoins:Show()
end

-- Function to handle Player 2 Main Bet Text
function player2PlaceTextMainBet(message)
    player2HistoryMainBet = string.match(message, "(%d+)G")

        if player2HistoryMainBet then
            player2MainBetAmount:SetText(player2HistoryMainBet .. " G")
            player2MainBetAmount:Show()

            if playerName == unitName2 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName2]
                    player2totalBetAmount = player2totalBetAmount + tonumber(player2HistoryMainBet)
                    bankingInfo.totalWagered = player2totalBetAmount
                end
            end

            historyFrame.player2totalWageredAmount:SetText(player2totalBetAmount .. " G")

        else
    end
end

-- Player 2 Split Hand Bet Text
function player2SplitHand1BetText(Amount)
    player2MainBetAmount:Hide()
    player2MainBetAmount:SetText("")
    player2SplitH1BetAmount:SetText(Amount .. " G")
    player2SplitH1BetAmount:Show()
    player2SplitH2BetAmount:SetText(Amount .. " G")
    player2SplitH2BetAmount:Show()
end

-- Player 2 Split Bet Image
function player2PlaceSplitBet(message)
    playerFrame.player2MainBetCoins:Hide()
    playerFrame.player2SplitHand1Coins:Show()
    playerFrame.player2SplitHand2Coins:Show()
end

-- Player 2 Place Initial Card Images
function player2PlaceSplitCards(message)

    -- Players: 2
    if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
        drawnCards[1]:Hide()
        drawnCards[3]:Hide()
        player2cardName1 = dealtCards[1]
        player2cardName2 = dealtCards[3]
        turn = 8 -- Player 2: 2nd Card (Split H1)

    -- Players: 1, 2
    elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
        drawnCards[2]:Hide()
        drawnCards[5]:Hide()
        player2cardName1 = dealtCards[2]
        player2cardName2 = dealtCards[5]
        turn = 30 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 3
    elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
        drawnCards[1]:Hide()
        drawnCards[4]:Hide()
        player2cardName1 = dealtCards[1]
        player2cardName2 = dealtCards[4]
        turn = 10 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 4
    elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
        drawnCards[1]:Hide()
        drawnCards[4]:Hide()
        player2cardName1 = dealtCards[1]
        player2cardName2 = dealtCards[4]
        turn = 10 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 5
    elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
        drawnCards[1]:Hide()
        drawnCards[4]:Hide()
        player2cardName1 = dealtCards[1]
        player2cardName2 = dealtCards[4]
        turn = 10 -- Player 2: 2nd Card (Split H1)
        
    -- Players: 1, 2, 3
    elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
        drawnCards[2]:Hide()
        drawnCards[6]:Hide()
        player2cardName1 = dealtCards[2]
        player2cardName2 = dealtCards[6]
        turn = 32 -- Player 2: 2nd Card (Split H1)
    -- Players: 1, 2, 4
    elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
        drawnCards[2]:Hide()
        drawnCards[6]:Hide()
        player2cardName1 = dealtCards[2]
        player2cardName2 = dealtCards[6]
        turn = 32 -- Player 2: 2nd Card (Split H1)
    -- Players: 1, 2, 5
    elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
        drawnCards[2]:Hide()
        drawnCards[6]:Hide()
        player2cardName1 = dealtCards[2]
        player2cardName2 = dealtCards[6]
        turn = 32 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 3, 4
    elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
        drawnCards[1]:Hide()
        drawnCards[5]:Hide()
        player2cardName1 = dealtCards[1]
        player2cardName2 = dealtCards[5]
        turn = 12 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 3, 5
    elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
        drawnCards[1]:Hide()
        drawnCards[5]:Hide()
        player2cardName1 = dealtCards[1]
        player2cardName2 = dealtCards[5]
        turn = 12 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 4, 5
    elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
        drawnCards[1]:Hide()
        drawnCards[5]:Hide()
        player2cardName1 = dealtCards[1]
        player2cardName2 = dealtCards[5]
        turn = 12 -- Player 2: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4
    elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
        drawnCards[2]:Hide()
        drawnCards[7]:Hide()
        player2cardName1 = dealtCards[2]
        player2cardName2 = dealtCards[7]
        turn = 34 -- Player 2: 2nd Card (Split H1)
    -- Players: 1, 2, 3, 5
    elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
        drawnCards[2]:Hide()
        drawnCards[7]:Hide()
        player2cardName1 = dealtCards[2]
        player2cardName2 = dealtCards[7]
        turn = 34 -- Player 2: 2nd Card (Split H1)
    -- Players: 1, 2, 4, 5
    elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
        drawnCards[2]:Hide()
        drawnCards[7]:Hide()
        player2cardName1 = dealtCards[2]
        player2cardName2 = dealtCards[7]
        turn = 34 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 3, 4, 5
    elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
        drawnCards[1]:Hide()
        drawnCards[6]:Hide()
        player2cardName1 = dealtCards[1]
        player2cardName2 = dealtCards[6]
        turn = 14 -- Player 2: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4, 5
    elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
        drawnCards[2]:Hide()
        drawnCards[8]:Hide()
        player2cardName1 = dealtCards[2]
        player2cardName2 = dealtCards[8]
        turn = 36 -- Player 2: 2nd Card (Split H1)

    end

    player2cardImageFile1 = nil
    player2cardImageFile2 = nil

    for filename, cardDescription in pairs(cardNames) do
        if cardDescription == player2cardName1 then
            player2cardImageFile1 = filename
            break
        end
    end

    for filename, cardDescription in pairs(cardNames) do
        if cardDescription == player2cardName2 then
            player2cardImageFile2 = filename
            break
        end
    end

    player2NewCardImage1 = CreateFrame("Frame", nil, playerFrame)
    player2NewCardImage1:SetSize(32, 64)
    player2NewCardImage1:SetPoint("BOTTOM", playerFrame, 185, 350)
    player2NewCardImage1.texture = player2NewCardImage1:CreateTexture()
    player2NewCardImage1.texture:SetAllPoints()
    player2NewCardImage1.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2cardImageFile1)
    player2NewCardImage1:Show()

    player2NewCardImage2 = CreateFrame("Frame", nil, playerFrame)
    player2NewCardImage2:SetSize(32, 64)
    player2NewCardImage2:SetPoint("BOTTOM", playerFrame, 143, 330)
    player2NewCardImage2.texture = player2NewCardImage2:CreateTexture()
    player2NewCardImage2.texture:SetAllPoints()
    player2NewCardImage2.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2cardImageFile2)
    player2NewCardImage2:Show()

end

-- Player 2 Split Function
function player2HandleSplit(message)
    player2PlaceSplitBet()
    player2MainBetAmountValue = tonumber(string.match(player2MainBetAmount:GetText(), "%d+"))
    if player2MainBetAmountValue then
        player2SplitHand1BetText(player2MainBetAmountValue)
    end 

    player2PlaceSplitCards()

    -- A,A
    if playerFrame.player2CardTotalText:GetText() == "2 or 12" then
        playerFrame.player2SplitHand1CardTotalText:SetText("1 or 11")
        playerFrame.player2SplitHand1CardTotalText:Show()
        playerFrame.player2SplitHand2CardTotalText:SetText("1 or 11")
        playerFrame.player2SplitHand2CardTotalText:Show()
    -- 2,2
    elseif playerFrame.player2CardTotalText:GetText() == "4" then
        playerFrame.player2SplitHand1CardTotalText:SetText("2")
        playerFrame.player2SplitHand1CardTotalText:Show()
        playerFrame.player2SplitHand2CardTotalText:SetText("2")
        playerFrame.player2SplitHand2CardTotalText:Show()
    -- 3,3
    elseif playerFrame.player2CardTotalText:GetText() == "6" then
        playerFrame.player2SplitHand1CardTotalText:SetText("3")
        playerFrame.player2SplitHand1CardTotalText:Show()
        playerFrame.player2SplitHand2CardTotalText:SetText("3")
        playerFrame.player2SplitHand2CardTotalText:Show()
    -- 4,4
    elseif playerFrame.player2CardTotalText:GetText() == "8" then
        playerFrame.player2SplitHand1CardTotalText:SetText("4")
        playerFrame.player2SplitHand1CardTotalText:Show()
        playerFrame.player2SplitHand2CardTotalText:SetText("4")
        playerFrame.player2SplitHand2CardTotalText:Show()
    -- 5,5
    elseif playerFrame.player2CardTotalText:GetText() == "10" then
        playerFrame.player2SplitHand1CardTotalText:SetText("5")
        playerFrame.player2SplitHand1CardTotalText:Show()
        playerFrame.player2SplitHand2CardTotalText:SetText("5")
        playerFrame.player2SplitHand2CardTotalText:Show()
    -- 6,6
    elseif playerFrame.player2CardTotalText:GetText() == "12" then
        playerFrame.player2SplitHand1CardTotalText:SetText("6")
        playerFrame.player2SplitHand1CardTotalText:Show()
        playerFrame.player2SplitHand2CardTotalText:SetText("6")
        playerFrame.player2SplitHand2CardTotalText:Show()
    -- 7,7
    elseif playerFrame.player2CardTotalText:GetText() == "14" then
        playerFrame.player2SplitHand1CardTotalText:SetText("7")
        playerFrame.player2SplitHand1CardTotalText:Show()
        playerFrame.player2SplitHand2CardTotalText:SetText("7")
        playerFrame.player2SplitHand2CardTotalText:Show()
    -- 8,8
    elseif playerFrame.player2CardTotalText:GetText() == "16" then
        playerFrame.player2SplitHand1CardTotalText:SetText("8")
        playerFrame.player2SplitHand1CardTotalText:Show()
        playerFrame.player2SplitHand2CardTotalText:SetText("8")
        playerFrame.player2SplitHand2CardTotalText:Show()
    -- 9,9
    elseif playerFrame.player2CardTotalText:GetText() == "18" then
        playerFrame.player2SplitHand1CardTotalText:SetText("9")
        playerFrame.player2SplitHand1CardTotalText:Show()
        playerFrame.player2SplitHand2CardTotalText:SetText("9")
        playerFrame.player2SplitHand2CardTotalText:Show()
    -- 10,10
    elseif playerFrame.player2CardTotalText:GetText() == "20" then
        playerFrame.player2SplitHand1CardTotalText:SetText("10")
        playerFrame.player2SplitHand1CardTotalText:Show()
        playerFrame.player2SplitHand2CardTotalText:SetText("10")
        playerFrame.player2SplitHand2CardTotalText:Show()
    end

    playerFrame.player2CardTotalText:SetText("")
    playerFrame.player2CardTotalText:Hide()
    
    if playerName == unitName2 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player2totalBetAmount = player2totalBetAmount + tonumber(player2MainBetAmountValue)
            bankingInfo.totalWagered = player2totalBetAmount
            player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(player2MainBetAmountValue)
            bankingInfo.bankrollTable = player2TotalBankrollAmount
        end
    end

    historyFrame.player2totalWageredAmount:SetText(player2totalBetAmount .. " G")
    bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
    cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

    player2SplitToggle = true

    if player2dealtCardsFrame:IsShown() then
        player2dealtCardsFrame:Hide()
        player2dealtCardsFrame.playerCardsButton:Hide()
        player2dealtCardsFrameSplitH1:Show()
        player2dealtCardsFrameSplitH1.playerH1CardsButton:Show()
        player2dealtCardsFrameSplitH1.playerH2CardsButton:Show()
    end

end

-- Function to handle Player 2 PP Bet Image
function player2PlaceCoinsPPBet(message)
    playerFrame.player2PPBetCoins:Show()
end

-- Function to handle Player 2 PP Bet Text
function player2PlaceTextPPBet(message)
    player2HistoryPPBet = string.match(message, "(%d+)G")

        if player2HistoryPPBet then
            player2PPBetAmount:SetText(player2HistoryPPBet .. " G")
            player2PPBetAmount:Show()

            if playerName == unitName2 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName2]
                    player2totalBetAmount = player2totalBetAmount + tonumber(player2HistoryPPBet)
                    bankingInfo.totalWagered = player2totalBetAmount
                end
            end

            historyFrame.player2totalWageredAmount:SetText(player2totalBetAmount .. " G")

        else
    end
end

-- Function to handle Player 2 21+3 Bet Image
function player2PlaceCoins213Bet(message)
    playerFrame.player2213BetCoins:Show()
end

-- Function to handle Player 2 21+3 Bet Text
function player2PlaceText213Bet(message)
    player2History213Bet = string.match(message, "(%d+)G")

        if player2History213Bet then
            player2213BetAmount:SetText(player2History213Bet .. " G")
            player2213BetAmount:Show()

            if playerName == unitName2 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName2]
                    player2totalBetAmount = player2totalBetAmount + tonumber(player2History213Bet)
                    bankingInfo.totalWagered = player2totalBetAmount
                end
            end

            historyFrame.player2totalWageredAmount:SetText(player2totalBetAmount .. " G")

        else
    end
end

function player2PreloadBet()
    
    player2MainBet = tonumber(player2PreloadEditBoxMainBet:GetText()) or 0
    player2PPBet = tonumber(player2PreloadEditBoxPPBet:GetText()) or 0
    player2213Bet = tonumber(player2PreloadEditBox213Bet:GetText()) or 0

    player2TotalRebetAmount = player2MainBet + player2PPBet + player2213Bet

    player2currentBankroll = tonumber(string.match(bankrollFrame.player2TotalBankrollTableDisplay:GetText(), "%d+"))

    if player2currentBankroll - player2TotalRebetAmount < 0 then
        print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
    else
        player2Threshold = minBetMain - 1
        if player2MainBet <= player2Threshold then
            print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
        else
            if player2MainBet and player2MainBet >= minBetMain and player2MainBet <= maxBetMain then
                PlaySoundFile(soundFilePaths[33])
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P2] PIacing a " ..player2MainBet.. "G main bet.", "RAID")
                -- Disable the edit box and button
                player2PreloadEditBoxMainBet:SetFocus(false)
                player2PreloadEditBoxMainBet:ClearFocus()
                player2MainBetEditBox:SetText("")
                player2MainBetEditBox:SetText(player2MainBet)
                player2MainBetEditBox:SetFocus(false)
                player2MainBetEditBox:ClearFocus()
                player2MainBetEditBox:Disable()
                player2ConfirmMainBetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(player2MainBet)
                    bankingInfo.bankrollTable = player2TotalBankrollAmount
                end
            end

            if player2PPBet and player2PPBet >= minBetPP and player2PPBet <= maxBetPP then
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P2] PIacing a " ..player2PPBet.. "G side bet on Perfect Pairs.", "RAID")
                -- Disable the edit box and button
                player2PreloadEditBoxPPBet:SetFocus(false)
                player2PreloadEditBoxPPBet:ClearFocus()
                player2PPBetEditBox:SetText("")
                player2PPBetEditBox:SetText(player2PPBet)
                player2PPBetEditBox:SetFocus(false)
                player2PPBetEditBox:ClearFocus()
                player2PPBetEditBox:Disable()
                player2ConfirmPPBetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(player2PPBet)
                    bankingInfo.bankrollTable = player2TotalBankrollAmount
                end
            end

            if player2213Bet and player2213Bet >= minBet213 and player2213Bet <= maxBet213 then
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P2] PIacing a " ..player2213Bet.. "G side bet on 21+3.", "RAID")
                -- Disable the edit box and button
                player2PreloadEditBox213Bet:SetFocus(false)
                player2PreloadEditBox213Bet:ClearFocus()
                player2213BetEditBox:SetText("")
                player2213BetEditBox:SetText(player2213Bet)
                player2213BetEditBox:SetFocus(false)
                player2213BetEditBox:ClearFocus()
                player2213BetEditBox:Disable()
                player2Confirm213BetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(player2213Bet)
                    bankingInfo.bankrollTable = player2TotalBankrollAmount
                end
            end
            
            player2PreloadBetButton:Disable()

        end

        bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

    end

end

-- Function to handle the Player 1 Main "Bet" button click
function player2ConfirmMainBetClick()
    player2MainBet = tonumber(player2MainBetEditBox:GetText())
    player2currentBankroll = tonumber(string.match(bankrollFrame.player2TotalBankrollTableDisplay:GetText(), "%d+"))

    if player2MainBet and player2MainBet >= minBetMain and player2MainBet <= maxBetMain then
        if player2currentBankroll - player2MainBet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            -- Valid bet amount, send the message with the bet
            SendChatMessage("[P2] PIacing a " ..player2MainBet.. "G main bet.", "RAID")
            -- Disable the edit box and button
            player2MainBetEditBox:SetFocus(false)
            player2MainBetEditBox:ClearFocus()
            player2MainBetEditBox:Disable()
            player2ConfirmMainBetButton:Disable()

            player2PreloadBetButton:Disable()

            PlaySoundFile(soundFilePaths[33]) 

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(player2MainBet)
                bankingInfo.bankrollTable = player2TotalBankrollAmount
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBetMain .. "G and " .. maxBetMain .. "G.")
    end

end

-- Function to handle the Player 1 PP "Bet" button click
function player2ConfirmPPBetClick()
    player2PPBet = tonumber(player2PPBetEditBox:GetText()) -- Get the entered bet amount
    player2currentBankroll = tonumber(string.match(bankrollFrame.player2TotalBankrollTableDisplay:GetText(), "%d+"))

    if player2PPBet and player2PPBet >= minBetPP and player2PPBet <= maxBetPP then
        if player2currentBankroll - player2PPBet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            if not player2Active then
                print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
            else
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P2] PIacing a " ..player2PPBet.. "G side bet on Perfect Pairs.", "RAID")
                -- Disable the edit box and button
                player2PPBetEditBox:SetFocus(false)
                player2PPBetEditBox:ClearFocus()
                player2PPBetEditBox:Disable()
                player2ConfirmPPBetButton:Disable()

                player2PreloadBetButton:Disable()

                PlaySoundFile(soundFilePaths[33])

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(player2PPBet)
                    bankingInfo.bankrollTable = player2TotalBankrollAmount
                end

                bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
                cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

            end
        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBetPP .. "G and " .. maxBetPP .. "G.")
    end

end

-- Function to handle the Player 1 21+3 "Bet" button click
function player2Confirm213BetClick()
    player2213Bet = tonumber(player2213BetEditBox:GetText()) -- Get the entered bet amount
    player2currentBankroll = tonumber(string.match(bankrollFrame.player2TotalBankrollTableDisplay:GetText(), "%d+"))

    if player2213Bet and player2213Bet >= minBet213 and player2213Bet <= maxBet213 then
        if player2currentBankroll - player2213Bet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            if not player2Active then
                print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
            else
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P2] PIacing a " ..player2213Bet.. "G side bet on 21+3.", "RAID")
                -- Disable the edit box and button
                player2213BetEditBox:SetFocus(false)
                player2213BetEditBox:ClearFocus()
                player2213BetEditBox:Disable()
                player2Confirm213BetButton:Disable()

                player2PreloadBetButton:Disable()

                PlaySoundFile(soundFilePaths[33])

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(player2213Bet)
                    bankingInfo.bankrollTable = player2TotalBankrollAmount
                end

                bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
                cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

            end
        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBet213 .. "G and " .. maxBet213 .. "G.")
    end
 
end

-- Player 2 Main "Bet" button
player2ConfirmMainBetButton:SetScript("OnClick", player2ConfirmMainBetClick)

-- Player 2 PP "Bet" button
player2ConfirmPPBetButton:SetScript("OnClick", player2ConfirmPPBetClick)

-- Player 2 21+3 "Bet" button
player2Confirm213BetButton:SetScript("OnClick", player2Confirm213BetClick)

-- Player 2 "Bet All" Preload button
player2PreloadBetButton:SetScript("OnClick", player2PreloadBet)

function player2resetRaidChannel()
    if playerName == unitName2 then
        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/raid", chatFrame)
        
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:SetText("")
        editBox:Insert("/raid")
        
        ChatEdit_SendText(editBox)
        ChatEdit_DeactivateChat(editBox)
    else
        print("")
    end
end

player2HotstreakImage1 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage1:SetSize(36, 36)
player2HotstreakImage1:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak1.tga")
player2HotstreakImage1:SetDrawLayer("OVERLAY")
player2HotstreakImage1:Hide()

player2HotstreakImage2 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage2:SetSize(36, 36)
player2HotstreakImage2:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak2.tga")
player2HotstreakImage2:SetDrawLayer("OVERLAY")
player2HotstreakImage2:Hide()

player2HotstreakImage3 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage3:SetSize(36, 36)
player2HotstreakImage3:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak3.tga")
player2HotstreakImage3:SetDrawLayer("OVERLAY")
player2HotstreakImage3:Hide()

player2HotstreakImage4 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage4:SetSize(36, 36)
player2HotstreakImage4:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak4.tga")
player2HotstreakImage4:SetDrawLayer("OVERLAY")
player2HotstreakImage4:Hide()

player2HotstreakImage5 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage5:SetSize(36, 36)
player2HotstreakImage5:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak5.tga")
player2HotstreakImage5:SetDrawLayer("OVERLAY")
player2HotstreakImage5:Hide()

player2HotstreakImage6 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage6:SetSize(36, 36)
player2HotstreakImage6:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak6.tga")
player2HotstreakImage6:SetDrawLayer("OVERLAY")
player2HotstreakImage6:Hide()

player2HotstreakImage7 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage7:SetSize(36, 36)
player2HotstreakImage7:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak7.tga")
player2HotstreakImage7:SetDrawLayer("OVERLAY")
player2HotstreakImage7:Hide()

player2HotstreakImage8 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage8:SetSize(36, 36)
player2HotstreakImage8:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage8:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak8.tga")
player2HotstreakImage8:SetDrawLayer("OVERLAY")
player2HotstreakImage8:Hide()

player2HotstreakImage9 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage9:SetSize(36, 36)
player2HotstreakImage9:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage9:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak9.tga")
player2HotstreakImage9:SetDrawLayer("OVERLAY")
player2HotstreakImage9:Hide()

player2HotstreakImage10 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage10:SetSize(36, 36)
player2HotstreakImage10:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage10:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak10.tga")
player2HotstreakImage10:SetDrawLayer("OVERLAY")
player2HotstreakImage10:Hide()

player2HotstreakImage11 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage11:SetSize(36, 36)
player2HotstreakImage11:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage11:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak11.tga")
player2HotstreakImage11:SetDrawLayer("OVERLAY")
player2HotstreakImage11:Hide()

player2HotstreakImage12 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage12:SetSize(36, 36)
player2HotstreakImage12:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage12:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak12.tga")
player2HotstreakImage12:SetDrawLayer("OVERLAY")
player2HotstreakImage12:Hide()

player2HotstreakImage13 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage13:SetSize(36, 36)
player2HotstreakImage13:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage13:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak13.tga")
player2HotstreakImage13:SetDrawLayer("OVERLAY")
player2HotstreakImage13:Hide()

player2HotstreakImage14 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage14:SetSize(36, 36)
player2HotstreakImage14:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage14:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak14.tga")
player2HotstreakImage14:SetDrawLayer("OVERLAY")
player2HotstreakImage14:Hide()

player2HotstreakImage15 = playerFrame:CreateTexture(nil, "OVERLAY")
player2HotstreakImage15:SetSize(36, 36)
player2HotstreakImage15:SetPoint("CENTER", playerFrame, 171, -228)
player2HotstreakImage15:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak15.tga")
player2HotstreakImage15:SetDrawLayer("OVERLAY")
player2HotstreakImage15:Hide()

function player2HotStreakCheck()
    if player2Hotstreak == 0 then
        player2HotstreakImage1:Hide()
        player2HotstreakImage2:Hide()
        player2HotstreakImage3:Hide()
        player2HotstreakImage4:Hide()
        player2HotstreakImage5:Hide()
        player2HotstreakImage6:Hide()
        player2HotstreakImage7:Hide()
        player2HotstreakImage8:Hide()
        player2HotstreakImage9:Hide()
        player2HotstreakImage10:Hide()
        player2HotstreakImage11:Hide()
        player2HotstreakImage12:Hide()
        player2HotstreakImage13:Hide()
        player2HotstreakImage14:Hide()
        player2HotstreakImage15:Hide()
    elseif player2Hotstreak == 1 then
        player2HotstreakImage1:Show()
    elseif player2Hotstreak == 2 then
        player2HotstreakImage1:Hide()
        player2HotstreakImage2:Show()
    elseif player2Hotstreak == 3 then
        player2HotstreakImage1:Hide()
        player2HotstreakImage2:Hide()
        player2HotstreakImage3:Show()
    elseif player2Hotstreak == 4 then
        player2HotstreakImage2:Hide()
        player2HotstreakImage3:Hide()
        player2HotstreakImage4:Show()
    elseif player2Hotstreak == 5 then
        player2HotstreakImage3:Hide()
        player2HotstreakImage4:Hide()
        player2HotstreakImage5:Show()
    elseif player2Hotstreak == 6 then
        player2HotstreakImage4:Hide()
        player2HotstreakImage5:Hide()
        player2HotstreakImage6:Show()
    elseif player2Hotstreak == 7 then
        player2HotstreakImage5:Hide()
        player2HotstreakImage6:Hide()
        player2HotstreakImage7:Show()
    elseif player2Hotstreak == 8 then
        player2HotstreakImage6:Hide()
        player2HotstreakImage7:Hide()
        player2HotstreakImage8:Show()
    elseif player2Hotstreak == 9 then
        player2HotstreakImage7:Hide()
        player2HotstreakImage8:Hide()
        player2HotstreakImage9:Show()
    elseif player2Hotstreak == 10 then
        player2HotstreakImage8:Hide()
        player2HotstreakImage9:Hide()
        player2HotstreakImage10:Show()
    elseif player2Hotstreak == 11 then
        player2HotstreakImage9:Hide()
        player2HotstreakImage10:Hide()
        player2HotstreakImage11:Show()
    elseif player2Hotstreak == 12 then
        player2HotstreakImage10:Hide()
        player2HotstreakImage11:Hide()
        player2HotstreakImage12:Show()
    elseif player2Hotstreak == 13 then
        player2HotstreakImage11:Hide()
        player2HotstreakImage12:Hide()
        player2HotstreakImage13:Show()
    elseif player2Hotstreak == 14 then
        player2HotstreakImage12:Hide()
        player2HotstreakImage13:Hide()
        player2HotstreakImage14:Show()
    elseif player2Hotstreak == 15 then
        player2HotstreakImage13:Hide()
        player2HotstreakImage14:Hide()
        player2HotstreakImage15:Show()
    end
end

-- Function to handle Player 2 PP Win Image
function player2PlaceBetsPPWin(message)
    playerFrame.player2PPBetCoins:Hide()
    playerFrame.player2PPWinCoins:Show()
    player2PPBetAmount:SetPoint("CENTER", playerFrame, 123, -6)
end

-- Function to handle Player 2 21+3 Win Image
function player2PlaceBets213Win(message)
    playerFrame.player2213BetCoins:Hide()
    playerFrame.player2213WinCoins:Show()
    player2213BetAmount:SetPoint("CENTER", playerFrame, 231, 46)
end

function player2MixedPairWin(message)

    if playerName == unitName2 then
        player2PPBetAmountValue = tonumber(string.match(player2PPBetEditBox:GetText(), "%d+"))
        if player2PPBetAmountValue then
            player2NewPPAmount = player2PPBetAmountValue * mixedPairPayoutReturn
            player2PPBetAmount:SetText(player2NewPPAmount .. " G")
            player2PPBetAmount:SetTextColor(0, 1, 0)

            player2PPProfitvalue = player2NewPPAmount - player2PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player2totalWin = player2totalWin + tonumber(player2PPProfitvalue)
                    bankingInfo.totalWon = player2totalWin
                    player2totalProfit = player2totalProfit + tonumber(player2PPProfitvalue)
                    bankingInfo.totalProfit = player2totalProfit
                    player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2NewPPAmount)
                    bankingInfo.bankrollTable = player2TotalBankrollAmount
                end

            historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
            historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
            if player2totalProfit >= 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        end
    else
        player2PPBetAmountValue = tonumber(string.match(player2PPBetAmount:GetText(), "%d+"))
        if player2PPBetAmountValue then
            player2NewPPAmount = player2PPBetAmountValue * mixedPairPayoutReturn
            player2PPBetAmount:SetText(player2NewPPAmount .. " G")
            player2PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player2PlaceBetsPPWin()
    player2PPSideBetWin = true

    player2SessionWin = player2SessionWin + tonumber(player2NewPPAmount)

end

function player2ColouredPairWin(message)

    if playerName == unitName2 then
        player2PPBetAmountValue = tonumber(string.match(player2PPBetEditBox:GetText(), "%d+"))
        if player2PPBetAmountValue then
            player2NewPPAmount = player2PPBetAmountValue * colouredPairPayoutReturn
            player2PPBetAmount:SetText(player2NewPPAmount .. " G")
            player2PPBetAmount:SetTextColor(0, 1, 0)

            player2PPProfitvalue = player2NewPPAmount - player2PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player2totalWin = player2totalWin + tonumber(player2PPProfitvalue)
                    bankingInfo.totalWon = player2totalWin
                    player2totalProfit = player2totalProfit + tonumber(player2PPProfitvalue)
                    bankingInfo.totalProfit = player2totalProfit
                    player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2NewPPAmount)
                    bankingInfo.bankrollTable = player2TotalBankrollAmount
                end

            historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
            historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
            if player2totalProfit >= 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        end
    else
        player2PPBetAmountValue = tonumber(string.match(player2PPBetAmount:GetText(), "%d+"))
        if player2PPBetAmountValue then
            player2NewPPAmount = player2PPBetAmountValue * colouredPairPayoutReturn
            player2PPBetAmount:SetText(player2NewPPAmount .. " G")
            player2PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player2PlaceBetsPPWin()
    player2PPSideBetWin = true

    player2SessionWin = player2SessionWin + tonumber(player2NewPPAmount)

end

function player2PerfectPairWin(message)

    if playerName == unitName2 then
        player2PPBetAmountValue = tonumber(string.match(player2PPBetEditBox:GetText(), "%d+"))
        if player2PPBetAmountValue then
            player2NewPPAmount = player2PPBetAmountValue * perfectPairPayoutReturn
            player2PPBetAmount:SetText(player2NewPPAmount .. " G")
            player2PPBetAmount:SetTextColor(0, 1, 0)

            player2PPProfitvalue = player2NewPPAmount - player2PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player2totalWin = player2totalWin + tonumber(player2PPProfitvalue)
                    bankingInfo.totalWon = player2totalWin
                    player2totalProfit = player2totalProfit + tonumber(player2PPProfitvalue)
                    bankingInfo.totalProfit = player2totalProfit
                    player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2NewPPAmount)
                    bankingInfo.bankrollTable = player2TotalBankrollAmount
                end

            historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
            historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
            if player2totalProfit >= 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        end
    else
        player2PPBetAmountValue = tonumber(string.match(player2PPBetAmount:GetText(), "%d+"))
        if player2PPBetAmountValue then
            player2NewPPAmount = player2PPBetAmountValue * perfectPairPayoutReturn
            player2PPBetAmount:SetText(player2NewPPAmount .. " G")
            player2PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player2PlaceBetsPPWin()
    player2PPSideBetWin = true

    player2SessionWin = player2SessionWin + tonumber(player2NewPPAmount)

end

function player2SuitedThreeOfAKindWin(message)

    if playerName == unitName2 then
        player2213BetAmountValue = tonumber(string.match(player2213BetEditBox:GetText(), "%d+"))
        if player2213BetAmountValue then
            player2New213Amount = player2213BetAmountValue * suitedThreeOfAKindPayoutReturn
            player2213BetAmount:SetText(player2New213Amount .. " G")
            player2213BetAmount:SetTextColor(0, 1, 0)

            player2213Profitvalue = player2New213Amount - player2213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2totalWin = player2totalWin + tonumber(player2213Profitvalue)
                bankingInfo.totalWon = player2totalWin
                player2totalProfit = player2totalProfit + tonumber(player2213Profitvalue)
                bankingInfo.totalProfit = player2totalProfit
                player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2New213Amount)
                bankingInfo.bankrollTable = player2TotalBankrollAmount
            end

            historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
            historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
            if player2totalProfit >= 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        end
    else
        player2213BetAmountValue = tonumber(string.match(player2213BetAmount:GetText(), "%d+"))
        if player2213BetAmountValue then
            player2New213Amount = player2213BetAmountValue * suitedThreeOfAKindPayoutReturn
            player2213BetAmount:SetText(player2New213Amount .. " G")
            player2213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player2PlaceBets213Win()
    player2213SideBetWin = true

    player2SessionWin = player2SessionWin + tonumber(player2New213Amount)

end

function player2StraightFlushWin(message)

    if playerName == unitName2 then
        player2213BetAmountValue = tonumber(string.match(player2213BetEditBox:GetText(), "%d+"))
        if player2213BetAmountValue then
            player2New213Amount = player2213BetAmountValue * straightFlushPayoutReturn
            player2213BetAmount:SetText(player2New213Amount .. " G")
            player2213BetAmount:SetTextColor(0, 1, 0)

            player2213Profitvalue = player2New213Amount - player2213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2totalWin = player2totalWin + tonumber(player2213Profitvalue)
                bankingInfo.totalWon = player2totalWin
                player2totalProfit = player2totalProfit + tonumber(player2213Profitvalue)
                bankingInfo.totalProfit = player2totalProfit
                player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2New213Amount)
                bankingInfo.bankrollTable = player2TotalBankrollAmount
            end

            historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
            historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
            if player2totalProfit >= 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        end
    else
        player2213BetAmountValue = tonumber(string.match(player2213BetAmount:GetText(), "%d+"))
        if player2213BetAmountValue then
            player2New213Amount = player2213BetAmountValue * straightFlushPayoutReturn
            player2213BetAmount:SetText(player2New213Amount .. " G")
            player2213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player2PlaceBets213Win()
    player2213SideBetWin = true

    player2SessionWin = player2SessionWin + tonumber(player2New213Amount)

end

function player2ThreeOfAKindWin(message)

    if playerName == unitName2 then
        player2213BetAmountValue = tonumber(string.match(player2213BetEditBox:GetText(), "%d+"))
        if player2213BetAmountValue then
            player2New213Amount = player2213BetAmountValue * threeOfAKindPayoutReturn
            player2213BetAmount:SetText(player2New213Amount .. " G")
            player2213BetAmount:SetTextColor(0, 1, 0)

            player2213Profitvalue = player2New213Amount - player2213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2totalWin = player2totalWin + tonumber(player2213Profitvalue)
                bankingInfo.totalWon = player2totalWin
                player2totalProfit = player2totalProfit + tonumber(player2213Profitvalue)
                bankingInfo.totalProfit = player2totalProfit
                player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2New213Amount)
                bankingInfo.bankrollTable = player2TotalBankrollAmount
            end

            historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
            historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
            if player2totalProfit >= 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        end
    else
        player2213BetAmountValue = tonumber(string.match(player2213BetAmount:GetText(), "%d+"))
        if player2213BetAmountValue then
            player2New213Amount = player2213BetAmountValue * threeOfAKindPayoutReturn
            player2213BetAmount:SetText(player2New213Amount .. " G")
            player2213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player2PlaceBets213Win()
    player2213SideBetWin = true

    player2SessionWin = player2SessionWin + tonumber(player2New213Amount)

end

function player2StraightWin(message)

    if playerName == unitName2 then
        player2213BetAmountValue = tonumber(string.match(player2213BetEditBox:GetText(), "%d+"))
        if player2213BetAmountValue then
            player2New213Amount = player2213BetAmountValue * straightPayoutReturn
            player2213BetAmount:SetText(player2New213Amount .. " G")
            player2213BetAmount:SetTextColor(0, 1, 0)

            player2213Profitvalue = player2New213Amount - player2213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2totalWin = player2totalWin + tonumber(player2213Profitvalue)
                bankingInfo.totalWon = player2totalWin
                player2totalProfit = player2totalProfit + tonumber(player2213Profitvalue)
                bankingInfo.totalProfit = player2totalProfit
                player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2New213Amount)
                bankingInfo.bankrollTable = player2TotalBankrollAmount
            end

            historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
            historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
            if player2totalProfit >= 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        end
    else
        player2213BetAmountValue = tonumber(string.match(player2213BetAmount:GetText(), "%d+"))
        if player2213BetAmountValue then
            player2New213Amount = player2213BetAmountValue * straightPayoutReturn
            player2213BetAmount:SetText(player2New213Amount .. " G")
            player2213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player2PlaceBets213Win()
    player2213SideBetWin = true

    player2SessionWin = player2SessionWin + tonumber(player2New213Amount)

end

function player2FlushWin(message)

    if playerName == unitName2 then
        player2213BetAmountValue = tonumber(string.match(player2213BetEditBox:GetText(), "%d+"))
        if player2213BetAmountValue then
            player2New213Amount = player2213BetAmountValue * flushPayoutReturn
            player2213BetAmount:SetText(player2New213Amount .. " G")
            player2213BetAmount:SetTextColor(0, 1, 0)

            player2213Profitvalue = player2New213Amount - player2213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2totalWin = player2totalWin + tonumber(player2213Profitvalue)
                bankingInfo.totalWon = player2totalWin
                player2totalProfit = player2totalProfit + tonumber(player2213Profitvalue)
                bankingInfo.totalProfit = player2totalProfit
                player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2New213Amount)
                bankingInfo.bankrollTable = player2TotalBankrollAmount
            end

            historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
            historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
            if player2totalProfit >= 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        end
    else
        player2213BetAmountValue = tonumber(string.match(player2213BetAmount:GetText(), "%d+"))
        if player2213BetAmountValue then
            player2New213Amount = player2213BetAmountValue * flushPayoutReturn
            player2213BetAmount:SetText(player2New213Amount .. " G")
            player2213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player2PlaceBets213Win()
    player2213SideBetWin = true

    player2SessionWin = player2SessionWin + tonumber(player2New213Amount)

end

function player2Loss()
    player2MainBetValue = tonumber(string.match(player2MainBetAmount:GetText(), "%d+"))
    if player2MainBetValue then
        
        if playerName == unitName2 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2totalLoss = player2totalLoss + tonumber(player2MainBetValue)
                bankingInfo.totalLost = player2totalLoss
                player2totalProfit = player2totalProfit - tonumber(player2MainBetValue)
                bankingInfo.totalProfit = player2totalProfit
            end
        end

        if player2totalProfit >= 0 then
            historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

        historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
        historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")

        player2PPBetText = player2PPBetAmount:GetText()

        if player2PPBetText and player2PPBetText ~= "" then
            player2PPBetAmountValue = tonumber(string.match(player2PPBetText, "%d+"))
            
            if player2PPBetAmountValue then
                if player2PPSideBetWin == false then

                    player2PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName2 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player2totalLoss = player2totalLoss + tonumber(player2PPBetAmountValue)
                            bankingInfo.totalLost = player2totalLoss
                            player2totalProfit = player2totalProfit - tonumber(player2PPBetAmountValue)
                            bankingInfo.totalProfit = player2totalProfit
                        end
                    end
            
                    if player2totalProfit >= 0 then
                        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end
            
                    historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")

                end
            end
        end

        player2213BetText = player2213BetAmount:GetText()

        if player2213BetText and player2213BetText ~= "" then
            player2213BetAmountValue = tonumber(string.match(player2213BetText, "%d+"))

            if player2213BetAmountValue then
                if player2213SideBetWin == false then

                    player2213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName2 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player2totalLoss = player2totalLoss + tonumber(player2213BetAmountValue)
                            bankingInfo.totalLost = player2totalLoss
                            player2totalProfit = player2totalProfit - tonumber(player2213BetAmountValue)
                            bankingInfo.totalProfit = player2totalProfit
                        end
                    end
            
                    if player2totalProfit >= 0 then
                        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end
            
                    historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")

                end
            end
        end
    end
end

function player2SplitH1Loss()
    player2SplitHand1BetAmountValue = tonumber(string.match(player2SplitH1BetAmount:GetText(), "%d+"))
    if player2SplitHand1BetAmountValue then

        if playerName == unitName2 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2totalLoss = player2totalLoss + tonumber(player2SplitHand1BetAmountValue)
                bankingInfo.totalLost = player2totalLoss
                player2totalProfit = player2totalProfit - tonumber(player2SplitHand1BetAmountValue)
                bankingInfo.totalProfit = player2totalProfit
            end
        end

        historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
        historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")

        if player2totalProfit >= 0 then
            historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

    end
end

function player2SplitH2Loss()
    player2SplitHand2BetAmountValue = tonumber(string.match(player2SplitH2BetAmount:GetText(), "%d+"))
    if player2SplitHand2BetAmountValue then

        if playerName == unitName2 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2totalLoss = player2totalLoss + tonumber(player2SplitHand2BetAmountValue)
                bankingInfo.totalLost = player2totalLoss
                player2totalProfit = player2totalProfit - tonumber(player2SplitHand2BetAmountValue)
                bankingInfo.totalProfit = player2totalProfit
            end
        end

        historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
        historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")

        if player2totalProfit >= 0 then
            historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

        player2PPBetText = player2PPBetAmount:GetText()

        if player2PPBetText and player2PPBetText ~= "" then
            player2PPBetAmountValue = tonumber(string.match(player2PPBetText, "%d+"))
            
            if player2PPBetAmountValue then
                if player2PPSideBetWin == false then

                    player2PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName2 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player2totalLoss = player2totalLoss + tonumber(player2PPBetAmountValue)
                            bankingInfo.totalLost = player2totalLoss
                            player2totalProfit = player2totalProfit - tonumber(player2PPBetAmountValue)
                            bankingInfo.totalProfit = player2totalProfit
                        end
                    end
            
                    historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
                    if player2totalProfit >= 0 then
                        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player2213BetText = player2213BetAmount:GetText()

        if player2213BetText and player2213BetText ~= "" then
            player2213BetAmountValue = tonumber(string.match(player2213BetText, "%d+"))

            if player2213BetAmountValue then
                if player2213SideBetWin == false then

                    player2213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName2 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player2totalLoss = player2totalLoss + tonumber(player2213BetAmountValue)
                            bankingInfo.totalLost = player2totalLoss
                            player2totalProfit = player2totalProfit - tonumber(player2213BetAmountValue)
                            bankingInfo.totalProfit = player2totalProfit
                        end
                    end
            
                    historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
                    if player2totalProfit >= 0 then
                        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

function player2Push()
    player2MainBetValue = tonumber(string.match(player2MainBetAmount:GetText(), "%d+"))
    if player2MainBetValue then


        if playerName == unitName2 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2MainBetValue)
                bankingInfo.bankrollTable = player2TotalBankrollAmount
            end
        end

        bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

        player2PPBetText = player2PPBetAmount:GetText()

        if player2PPBetText and player2PPBetText ~= "" then
            player2PPBetAmountValue = tonumber(string.match(player2PPBetText, "%d+"))
            
            if player2PPBetAmountValue then
                if player2PPSideBetWin == false then

                    player2PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName2 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player2totalLoss = player2totalLoss + tonumber(player2PPBetAmountValue)
                            bankingInfo.totalLost = player2totalLoss
                            player2totalProfit = player2totalProfit - tonumber(player2PPBetAmountValue)
                            bankingInfo.totalProfit = player2totalProfit
                        end
                    end
            
                    historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
                    if player2totalProfit >= 0 then
                        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player2213BetText = player2213BetAmount:GetText()

        if player2213BetText and player2213BetText ~= "" then
            player2213BetAmountValue = tonumber(string.match(player2213BetText, "%d+"))

            if player2213BetAmountValue then
                if player2213SideBetWin == false then

                    player2213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName2 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player2totalLoss = player2totalLoss + tonumber(player2213BetAmountValue)
                            bankingInfo.totalLost = player2totalLoss
                            player2totalProfit = player2totalProfit - tonumber(player2213BetAmountValue)
                            bankingInfo.totalProfit = player2totalProfit
                        end
                    end
            
                    historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
                    if player2totalProfit >= 0 then
                        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player2SessionWin = player2SessionWin + tonumber(player2MainBetValue)

    end
end

function player2SplitH1Push()
    player2SplitHand1BetAmountValue = tonumber(string.match(player2SplitH1BetAmount:GetText(), "%d+"))
    if player2SplitHand1BetAmountValue then

        if playerName == unitName2 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2SplitHand1BetAmountValue)
                bankingInfo.bankrollTable = player2TotalBankrollAmount
            end
        end

        bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
    
        player2SessionWin = player2SessionWin + tonumber(player2SplitHand1BetAmountValue)
    
    end
end

function player2SplitH2Push()
    player2SplitHand2BetAmountValue = tonumber(string.match(player2SplitH2BetAmount:GetText(), "%d+"))
    if player2SplitHand2BetAmountValue then

        if playerName == unitName2 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2SplitHand2BetAmountValue)
                bankingInfo.bankrollTable = player2TotalBankrollAmount
            end
        end

        bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

        player2PPBetText = player2PPBetAmount:GetText()

        if player2PPBetText and player2PPBetText ~= "" then
            player2PPBetAmountValue = tonumber(string.match(player2PPBetText, "%d+"))
            
            if player2PPBetAmountValue then
                if player2PPSideBetWin == false then

                    player2PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName2 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player2totalLoss = player2totalLoss + tonumber(player2PPBetAmountValue)
                            bankingInfo.totalLost = player2totalLoss
                            player2totalProfit = player2totalProfit - tonumber(player2PPBetAmountValue)
                            bankingInfo.totalProfit = player2totalProfit
                        end
                    end
            
                    historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
                    if player2totalProfit >= 0 then
                        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player2213BetText = player2213BetAmount:GetText()

        if player2213BetText and player2213BetText ~= "" then
            player2213BetAmountValue = tonumber(string.match(player2213BetText, "%d+"))

            if player2213BetAmountValue then
                if player2213SideBetWin == false then

                    player2213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName2 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player2totalLoss = player2totalLoss + tonumber(player2213BetAmountValue)
                            bankingInfo.totalLost = player2totalLoss
                            player2totalProfit = player2totalProfit - tonumber(player2213BetAmountValue)
                            bankingInfo.totalProfit = player2totalProfit
                        end
                    end
            
                    historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
                    if player2totalProfit >= 0 then
                        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    
        player2SessionWin = player2SessionWin + tonumber(player2SplitHand2BetAmountValue)
    
    end
end

function player2BJWin(message)
    player2MainBetAmountValue = tonumber(string.match(player2MainBetAmount:GetText(), "%d+"))
    if player2MainBetAmountValue then
        player2BJWinAmountValue = player2MainBetAmountValue * 2.5
        player2MainBetAmount:SetText(player2BJWinAmountValue .. " G")
    end

    player2BJProfitvalue = player2BJWinAmountValue - player2MainBetAmountValue

    if playerName == unitName2 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player2totalWin = player2totalWin + tonumber(player2BJProfitvalue)
            bankingInfo.totalWon = player2totalWin
            player2totalProfit = player2totalProfit + tonumber(player2BJProfitvalue)
            bankingInfo.totalProfit = player2totalProfit
            player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2BJWinAmountValue)
            bankingInfo.bankrollTable = player2TotalBankrollAmount
        end
    end

    if player2totalProfit >= 0 then
        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
    bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
    cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

    player2PPBetText = player2PPBetAmount:GetText()

    if player2PPBetText and player2PPBetText ~= "" then
        player2PPBetAmountValue = tonumber(string.match(player2PPBetText, "%d+"))
        
        if player2PPBetAmountValue then
            if player2PPSideBetWin == false then

                player2PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName2 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player2totalLoss = player2totalLoss + tonumber(player2PPBetAmountValue)
                        bankingInfo.totalLost = player2totalLoss
                        player2totalProfit = player2totalProfit - tonumber(player2PPBetAmountValue)
                        bankingInfo.totalProfit = player2totalProfit
                    end
                end
        
                historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
        
                if player2totalProfit >= 0 then
                    historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player2213BetText = player2213BetAmount:GetText()

    if player2213BetText and player2213BetText ~= "" then
        player2213BetAmountValue = tonumber(string.match(player2213BetText, "%d+"))

        if player2213BetAmountValue then
            if player2213SideBetWin == false then

                player2213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName2 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player2totalLoss = player2totalLoss + tonumber(player2213BetAmountValue)
                        bankingInfo.totalLost = player2totalLoss
                        player2totalProfit = player2totalProfit - tonumber(player2213BetAmountValue)
                        bankingInfo.totalProfit = player2totalProfit
                    end
                end
        
                historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
        
                if player2totalProfit >= 0 then
                    historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player2MainBetCoins:Hide()
    playerFrame.player2BJWinCoins:Show()

    player2SessionWin = player2SessionWin + tonumber(player2BJWinAmountValue)

end

function player2SplitH1BJ(message)
    player2SplitHand1BetAmountValue = tonumber(string.match(player2SplitH1BetAmount:GetText(), "%d+"))
    if player2SplitHand1BetAmountValue then
        player2SplitHand1BJWinAmountValue = player2SplitHand1BetAmountValue * 2.5
        player2SplitH1BetAmount:SetText(player2SplitHand1BJWinAmountValue .. " G")
    end

    player2SplitHand1BJProfitValue = player2SplitHand1BJWinAmountValue - player2SplitHand1BetAmountValue

    if playerName == unitName2 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player2totalWin = player2totalWin + tonumber(player2SplitHand1BJProfitValue)
            bankingInfo.totalWon = player2totalWin
            player2totalProfit = player2totalProfit + tonumber(player2SplitHand1BJProfitValue)
            bankingInfo.totalProfit = player2totalProfit
            player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2SplitHand1BJWinAmountValue)
            bankingInfo.bankrollTable = player2TotalBankrollAmount
        end
    end

    if player2totalProfit >= 0 then
        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
    bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
    cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

    playerFrame.player2SplitHand1Coins:Hide()
    playerFrame.player2SplitHand1BJWinCoins:Show()

    player2SessionWin = player2SessionWin + tonumber(player2SplitHand1BJWinAmountValue)

end

function player2SplitH2BJ(message)
    player2SplitHand2BetAmountValue = tonumber(string.match(player2SplitH2BetAmount:GetText(), "%d+"))
    if player2SplitHand2BetAmountValue then
        player2SplitHand2BJWinAmountValue = player2SplitHand2BetAmountValue * 2.5
        player2SplitH2BetAmount:SetText(player2SplitHand2BJWinAmountValue .. " G")
    end

    player2SplitHand2BJProfitValue = player2SplitHand2BJWinAmountValue - player2SplitHand2BetAmountValue

    if playerName == unitName2 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player2totalWin = player2totalWin + tonumber(player2SplitHand2BJProfitValue)
            bankingInfo.totalWon = player2totalWin
            player2totalProfit = player2totalProfit + tonumber(player2SplitHand2BJProfitValue)
            bankingInfo.totalProfit = player2totalProfit
            player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2SplitHand2BJWinAmountValue)
            bankingInfo.bankrollTable = player2TotalBankrollAmount
        end
    end

    if player2totalProfit >= 0 then
        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
    bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
    cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

    player2PPBetText = player2PPBetAmount:GetText()

    if player2PPBetText and player2PPBetText ~= "" then
        player2PPBetAmountValue = tonumber(string.match(player2PPBetText, "%d+"))
        
        if player2PPBetAmountValue then
            if player2PPSideBetWin == false then

                player2PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName2 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player2totalLoss = player2totalLoss + tonumber(player2PPBetAmountValue)
                        bankingInfo.totalLost = player2totalLoss
                        player2totalProfit = player2totalProfit - tonumber(player2PPBetAmountValue)
                        bankingInfo.totalProfit = player2totalProfit
                    end
                end
        
                historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
        
                if player2totalProfit >= 0 then
                    historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player2213BetText = player2213BetAmount:GetText()

    if player2213BetText and player2213BetText ~= "" then
        player2213BetAmountValue = tonumber(string.match(player2213BetText, "%d+"))

        if player2213BetAmountValue then
            if player2213SideBetWin == false then

                player2213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName2 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player2totalLoss = player2totalLoss + tonumber(player2213BetAmountValue)
                        bankingInfo.totalLost = player2totalLoss
                        player2totalProfit = player2totalProfit - tonumber(player2213BetAmountValue)
                        bankingInfo.totalProfit = player2totalProfit
                    end
                end
        
                historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
        
                if player2totalProfit >= 0 then
                    historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player2SplitHand2Coins:Hide()
    playerFrame.player2SplitHand2BJWinCoins:Show()

    player2SessionWin = player2SessionWin + tonumber(player2SplitHand2BJWinAmountValue)

end

function player2Win(message)
    player2MainBetAmountValue = tonumber(string.match(player2MainBetAmount:GetText(), "%d+"))
    if player2MainBetAmountValue then
        player2NormalWinAmountValue = player2MainBetAmountValue * 2
        player2MainBetAmount:SetText(player2NormalWinAmountValue .. " G")

        if playerName == unitName2 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player2totalWin = player2totalWin + tonumber(player2MainBetAmountValue)
                bankingInfo.totalWon = player2totalWin
                player2totalProfit = player2totalProfit + tonumber(player2MainBetAmountValue)
                bankingInfo.totalProfit = player2totalProfit
                player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2NormalWinAmountValue)
                bankingInfo.bankrollTable = player2TotalBankrollAmount
            end
        end
    
        if player2totalProfit >= 0 then
            historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end
    
        historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
        historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
        bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

        player2PPBetText = player2PPBetAmount:GetText()

        if player2PPBetText and player2PPBetText ~= "" then
            player2PPBetAmountValue = tonumber(string.match(player2PPBetText, "%d+"))
            
            if player2PPBetAmountValue then
                if player2PPSideBetWin == false then

                    player2PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName2 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player2totalLoss = player2totalLoss + tonumber(player2PPBetAmountValue)
                            bankingInfo.totalLost = player2totalLoss
                            player2totalProfit = player2totalProfit - tonumber(player2PPBetAmountValue)
                            bankingInfo.totalProfit = player2totalProfit
                        end
                    end
            
                    historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
                    if player2totalProfit >= 0 then
                        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player2213BetText = player2213BetAmount:GetText()

        if player2213BetText and player2213BetText ~= "" then
            player2213BetAmountValue = tonumber(string.match(player2213BetText, "%d+"))

            if player2213BetAmountValue then
                if player2213SideBetWin == false then

                    player2213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName2 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player2totalLoss = player2totalLoss + tonumber(player2213BetAmountValue)
                            bankingInfo.totalLost = player2totalLoss
                            player2totalProfit = player2totalProfit - tonumber(player2213BetAmountValue)
                            bankingInfo.totalProfit = player2totalProfit
                        end
                    end
            
                    historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            
                    if player2totalProfit >= 0 then
                        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end

    playerFrame.player2MainBetCoins:Hide()
    playerFrame.player2NormalWinCoins:Show()

    player2SessionWin = player2SessionWin + tonumber(player2NormalWinAmountValue)

end

function player2SplitH1Win(message)
    player2SplitHand1BetAmountValue = tonumber(string.match(player2SplitH1BetAmount:GetText(), "%d+"))
    if player2SplitHand1BetAmountValue then
        player2SplitHand1NormalWinAmountValue = player2SplitHand1BetAmountValue * 2
        player2SplitH1BetAmount:SetText(player2SplitHand1NormalWinAmountValue .. " G")
    end

    if playerName == unitName2 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player2totalWin = player2totalWin + tonumber(player2SplitHand1BetAmountValue)
            bankingInfo.totalWon = player2totalWin
            player2totalProfit = player2totalProfit + tonumber(player2SplitHand1BetAmountValue)
            bankingInfo.totalProfit = player2totalProfit
            player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2SplitHand1NormalWinAmountValue)
            bankingInfo.bankrollTable = player2TotalBankrollAmount
        end
    end

    if player2totalProfit >= 0 then
        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
    bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
    cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

    playerFrame.player2SplitHand1Coins:Hide()
    playerFrame.player2SplitHand1NormalWinCoins:Show()

    player2SessionWin = player2SessionWin + tonumber(player2SplitHand1NormalWinAmountValue)

end

function player2SplitH2Win(message)
    player2SplitHand2BetAmountValue = tonumber(string.match(player2SplitH2BetAmount:GetText(), "%d+"))
    if player2SplitHand2BetAmountValue then
        player2SplitHand2NormalWinAmountValue = player2SplitHand2BetAmountValue * 2
        player2SplitH2BetAmount:SetText(player2SplitHand2NormalWinAmountValue .. " G")
    end

    if playerName == unitName2 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player2totalWin = player2totalWin + tonumber(player2SplitHand2BetAmountValue)
            bankingInfo.totalWon = player2totalWin
            player2totalProfit = player2totalProfit + tonumber(player2SplitHand2BetAmountValue)
            bankingInfo.totalProfit = player2totalProfit
            player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2SplitHand2NormalWinAmountValue)
            bankingInfo.bankrollTable = player2TotalBankrollAmount
        end
    end

    if player2totalProfit >= 0 then
        historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
    historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
    bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
    cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

    player2PPBetText = player2PPBetAmount:GetText()

    if player2PPBetText and player2PPBetText ~= "" then
        player2PPBetAmountValue = tonumber(string.match(player2PPBetText, "%d+"))
        
        if player2PPBetAmountValue then
            if player2PPSideBetWin == false then

                player2PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName2 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player2totalLoss = player2totalLoss + tonumber(player2PPBetAmountValue)
                        bankingInfo.totalLost = player2totalLoss
                        player2totalProfit = player2totalProfit - tonumber(player2PPBetAmountValue)
                        bankingInfo.totalProfit = player2totalProfit
                    end
                end
        
                historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
        
                if player2totalProfit >= 0 then
                    historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player2213BetText = player2213BetAmount:GetText()

    if player2213BetText and player2213BetText ~= "" then
        player2213BetAmountValue = tonumber(string.match(player2213BetText, "%d+"))

        if player2213BetAmountValue then
            if player2213SideBetWin == false then

                player2213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName2 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player2totalLoss = player2totalLoss + tonumber(player2213BetAmountValue)
                        bankingInfo.totalLost = player2totalLoss
                        player2totalProfit = player2totalProfit - tonumber(player2213BetAmountValue)
                        bankingInfo.totalProfit = player2totalProfit
                    end
                end
        
                historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
                historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
        
                if player2totalProfit >= 0 then
                    historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player2SplitHand2Coins:Hide()
    playerFrame.player2SplitHand2NormalWinCoins:Show()

    player2SessionWin = player2SessionWin + tonumber(player2SplitHand2NormalWinAmountValue)

end

function player2InsuranceWin(message)

    player2InsuranceBetText = playerFrame.player2InsuranceBetAmount:GetText()

    if player2InsuranceBetText and player2InsuranceBetText ~= "" then
        player2InsuranceBetAmountValue = tonumber(string.match(player2InsuranceBetText, "%d+"))

        if player2InsuranceBetAmountValue then
            player2InsuranceWinAmountValue = player2InsuranceBetAmountValue * 3

            player2InsuranceProfitValue = player2InsuranceWinAmountValue - player2InsuranceBetAmountValue


            if playerName == unitName2 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player2totalWin = player2totalWin + tonumber(player2InsuranceProfitValue)
                    bankingInfo.totalWon = player2totalWin
                    player2totalProfit = player2totalProfit + tonumber(player2InsuranceProfitValue)
                    bankingInfo.totalProfit = player2totalProfit
                    player2TotalBankrollAmount = player2TotalBankrollAmount + tonumber(player2InsuranceWinAmountValue)
                    bankingInfo.bankrollTable = player2TotalBankrollAmount
                end
            end
        
            if player2totalProfit >= 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
        
            historyFrame.player2totalWonAmount:SetText(player2totalWin .. " G")
            historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")
            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")

            player2SessionWin = player2SessionWin + tonumber(player2InsuranceWinAmountValue)

        end
    end
end

function player2InsuranceLoss(message)

    player2InsuranceBetText = playerFrame.player2InsuranceBetAmount:GetText()

    if player2InsuranceBetText and player2InsuranceBetText ~= "" then
        player2InsuranceBetAmountValue = tonumber(string.match(player2InsuranceBetText, "%d+"))

        if player2InsuranceBetAmountValue then

            if playerName == unitName2 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player2totalLoss = player2totalLoss + tonumber(player2InsuranceBetAmountValue)
                    bankingInfo.totalLost = player2totalLoss
                    player2totalProfit = player2totalProfit - tonumber(player2InsuranceBetAmountValue)
                    bankingInfo.totalProfit = player2totalProfit
                end
            end
    
            if player2totalProfit >= 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
    
            historyFrame.player2totalLostAmount:SetText(player2totalLoss .. " G")
            historyFrame.player2ProfitAmount:SetText(player2totalProfit .. " G")

        end
    end
end

function player2SessionWinAnnouncement()
    if playerName == unitName2 then
        if player2SessionWinCalled == false then
            if player2SessionWin >= 50 then
                chatFrame = SELECTED_DOCK_FRAME
                ChatFrame_OpenChat("/me", chatFrame)
                
                editBox = _G[chatFrame:GetName().."EditBox"]
                editBox:SetText("")
                editBox:Insert("/me has won " .. player2SessionWin .. "g from a hand of Blackjack.")
                
                ChatEdit_SendText(editBox)
                ChatEdit_DeactivateChat(editBox)

                UpdateWinningsDisplay(playerFrame.player2WinningsUpdate, player2SessionWin)
                player2resetRaidChannel()
                
            else
                print("")
            end

            player2SessionWinCalled = true
        end
    end
end





















-- >>> PLAYER 3 <<<
-- >>> PLAYER 3 <<<
-- >>> PLAYER 3 <<<

playerFrame.player3CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", 4, 180)
playerFrame.player3CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 28, "OUTLINE") -- Adjust the font and size as needed
playerFrame.player3CardTotalText:SetText("")

playerFrame.player3SplitHand1CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3SplitHand1CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", 51, 188)
playerFrame.player3SplitHand1CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
playerFrame.player3SplitHand1CardTotalText:SetText("")

playerFrame.player3SplitHand2CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3SplitHand2CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", -42, 188)
playerFrame.player3SplitHand2CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
playerFrame.player3SplitHand2CardTotalText:SetText("")

-- Buttons for Player 3
-- Hit
playerFrame.player3HitButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3HitButton:SetPoint("BOTTOM", playerFrame, -33, 80)
playerFrame.player3HitButton:SetSize(65, 30)
playerFrame.player3HitButton:SetText("Hit")
playerFrame.player3HitButton:Disable()
playerFrame.player3HitButton:Hide()
-- Stand
playerFrame.player3StandButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3StandButton:SetPoint("BOTTOM", playerFrame, 33, 80)
playerFrame.player3StandButton:SetSize(65, 30)
playerFrame.player3StandButton:SetText("Stand")
playerFrame.player3StandButton:Disable()
playerFrame.player3StandButton:Hide()
-- Double
playerFrame.player3DoubleButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3DoubleButton:SetPoint("BOTTOM", playerFrame, -33, 50)
playerFrame.player3DoubleButton:SetSize(65, 30)
playerFrame.player3DoubleButton:SetText("Double")
playerFrame.player3DoubleButton:Disable()
playerFrame.player3DoubleButton:Hide()
-- Split
playerFrame.player3SplitButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3SplitButton:SetPoint("BOTTOM", playerFrame, 33, 50)
playerFrame.player3SplitButton:SetSize(65, 30)
playerFrame.player3SplitButton:SetText("Split")
playerFrame.player3SplitButton:Disable()
playerFrame.player3SplitButton:Hide()
-- Insurance Yes
playerFrame.player3InsuranceYesButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3InsuranceYesButton:SetPoint("BOTTOM", playerFrame, -65, 20)
playerFrame.player3InsuranceYesButton:SetSize(55, 30)
playerFrame.player3InsuranceYesButton:SetText("Yes")
playerFrame.player3InsuranceYesButton:Disable()
playerFrame.player3InsuranceYesButton:Hide()
-- Insurance No
playerFrame.player3InsuranceNoButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3InsuranceNoButton:SetPoint("BOTTOM", playerFrame, 63, 20)
playerFrame.player3InsuranceNoButton:SetSize(55, 30)
playerFrame.player3InsuranceNoButton:SetText("No")
playerFrame.player3InsuranceNoButton:Disable()
playerFrame.player3InsuranceNoButton:Hide()
-- Deal Now
playerFrame.player3DealNowButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3DealNowButton:SetPoint("BOTTOM", playerFrame, 0, 20)
playerFrame.player3DealNowButton:SetSize(85, 30)
playerFrame.player3DealNowButton:SetText("Deal Now")
playerFrame.player3DealNowButton:Disable()
playerFrame.player3DealNowButton:Hide()
-- Hit (Split H1)
playerFrame.player3HitButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3HitButtonSplitH1:SetPoint("BOTTOM", playerFrame, 33, 80)
playerFrame.player3HitButtonSplitH1:SetSize(65, 30)
playerFrame.player3HitButtonSplitH1:SetText("Hit")
playerFrame.player3HitButtonSplitH1:Disable()
playerFrame.player3HitButtonSplitH1:Hide()
-- Stand (Split H1)
playerFrame.player3StandButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3StandButtonSplitH1:SetPoint("BOTTOM", playerFrame, 33, 50)
playerFrame.player3StandButtonSplitH1:SetSize(65, 30)
playerFrame.player3StandButtonSplitH1:SetText("Stand")
playerFrame.player3StandButtonSplitH1:Disable()
playerFrame.player3StandButtonSplitH1:Hide()
-- Double (Split H1)
playerFrame.player3DoubleButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3DoubleButtonSplitH1:SetPoint("BOTTOM", playerFrame, 33, 20)
playerFrame.player3DoubleButtonSplitH1:SetSize(65, 30)
playerFrame.player3DoubleButtonSplitH1:SetText("Double")
playerFrame.player3DoubleButtonSplitH1:Disable()
playerFrame.player3DoubleButtonSplitH1:Hide()
-- Hit (Split H2)
playerFrame.player3HitButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3HitButtonSplitH2:SetPoint("BOTTOM", playerFrame, -33, 80)
playerFrame.player3HitButtonSplitH2:SetSize(65, 30)
playerFrame.player3HitButtonSplitH2:SetText("Hit")
playerFrame.player3HitButtonSplitH2:Disable()
playerFrame.player3HitButtonSplitH2:Hide()
-- Stand (Split H2)
playerFrame.player3StandButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3StandButtonSplitH2:SetPoint("BOTTOM", playerFrame, -33, 50)
playerFrame.player3StandButtonSplitH2:SetSize(65, 30)
playerFrame.player3StandButtonSplitH2:SetText("Stand")
playerFrame.player3StandButtonSplitH2:Disable()
playerFrame.player3StandButtonSplitH2:Hide()
-- Double (Split H2)
playerFrame.player3DoubleButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player3DoubleButtonSplitH2:SetPoint("BOTTOM", playerFrame, -33, 20)
playerFrame.player3DoubleButtonSplitH2:SetSize(65, 30)
playerFrame.player3DoubleButtonSplitH2:SetText("Double")
playerFrame.player3DoubleButtonSplitH2:Disable()
playerFrame.player3DoubleButtonSplitH2:Hide()
-- Main Bet Confirm
player3ConfirmMainBetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player3ConfirmMainBetButton:SetPoint("BOTTOM", playerFrame, 33, 140)
player3ConfirmMainBetButton:SetSize(65, 30)
player3ConfirmMainBetButton:SetText("Bet")
player3ConfirmMainBetButton:Hide()
-- Perfect Pairs Confirm
player3ConfirmPPBetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player3ConfirmPPBetButton:SetPoint("BOTTOM", playerFrame, -56, 232)
player3ConfirmPPBetButton:SetSize(43, 25)
player3ConfirmPPBetButton:SetText("Bet")
player3ConfirmPPBetButton:Hide()
-- 21+3 Confirm
player3Confirm213BetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player3Confirm213BetButton:SetPoint("BOTTOM", playerFrame, 64, 232)
player3Confirm213BetButton:SetSize(43, 25)
player3Confirm213BetButton:SetText("Bet")
player3Confirm213BetButton:Hide()

-- Wagers for Player 3
-- Main Bet
player3MainBetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player3MainBetEditBox:SetSize(55, 30)
player3MainBetEditBox:SetPoint("BOTTOM", playerFrame, -30, 140)
player3MainBetEditBox:SetAutoFocus(false)
player3MainBetEditBox:SetNumeric(true)
player3MainBetEditBox:Hide()
-- Split Hand 1
player3SplitH1EditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player3SplitH1EditBox:SetSize(55, 30)
player3SplitH1EditBox:SetPoint("BOTTOM", playerFrame, 35, 140)
player3SplitH1EditBox:SetAutoFocus(false)
player3SplitH1EditBox:SetNumeric(true)
player3SplitH1EditBox:ClearFocus()
player3SplitH1EditBox:Disable()
player3SplitH1EditBox:Hide()
-- Split Hand 2
player3SplitH2EditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player3SplitH2EditBox:SetSize(55, 30)
player3SplitH2EditBox:SetPoint("BOTTOM", playerFrame, -30, 140)
player3SplitH2EditBox:SetAutoFocus(false)
player3SplitH2EditBox:SetNumeric(true)
player3SplitH2EditBox:ClearFocus()
player3SplitH2EditBox:Disable()
player3SplitH2EditBox:Hide()
-- Perfect Pairs
player3PPBetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player3PPBetEditBox:SetSize(35, 30)
player3PPBetEditBox:SetPoint("BOTTOM", playerFrame, -54, 252)
player3PPBetEditBox:SetAutoFocus(false)
player3PPBetEditBox:SetNumeric(true)
player3PPBetEditBox:Hide()
-- 21+3
player3213BetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player3213BetEditBox:SetSize(35, 30)
player3213BetEditBox:SetPoint("BOTTOM", playerFrame, 66, 252)
player3213BetEditBox:SetAutoFocus(false)
player3213BetEditBox:SetNumeric(true)
player3213BetEditBox:Hide()

-- Labels for Player 3
-- Main Bet
playerFrame.player3MainBetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3MainBetTitle:SetPoint("BOTTOM", playerFrame, -31, 167)
playerFrame.player3MainBetTitle:SetJustifyH("CENTER")
playerFrame.player3MainBetTitle:SetText("Main Bet")
playerFrame.player3MainBetTitle:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player3MainBetTitle:Hide()
-- Split Hand 1
playerFrame.player3SplitH1Title = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3SplitH1Title:SetPoint("BOTTOM", playerFrame, 34, 167)
playerFrame.player3SplitH1Title:SetJustifyH("CENTER")
playerFrame.player3SplitH1Title:SetText("Hand 1")
playerFrame.player3SplitH1Title:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player3SplitH1Title:Hide()
-- Split Hand 2
playerFrame.player3SplitH2Title = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3SplitH2Title:SetPoint("BOTTOM", playerFrame, -31, 167)
playerFrame.player3SplitH2Title:SetJustifyH("CENTER")
playerFrame.player3SplitH2Title:SetText("Hand 2")
playerFrame.player3SplitH2Title:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player3SplitH2Title:Hide()
-- Main Bet Amount
player3MainBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3MainBetAmount:SetPoint("CENTER", playerFrame, 6, -59)
player3MainBetAmount:SetJustifyH("CENTER")
player3MainBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Split Hand 1 Amount
player3SplitH1BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3SplitH1BetAmount:SetPoint("CENTER", playerFrame, 24, -53)
player3SplitH1BetAmount:SetJustifyH("CENTER")
player3SplitH1BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Split Hand 2 Amount
player3SplitH2BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3SplitH2BetAmount:SetPoint("CENTER", playerFrame, -11, -53)
player3SplitH2BetAmount:SetJustifyH("CENTER")
player3SplitH2BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Perfect Pairs
playerFrame.player3PPBetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3PPBetTitle:SetPoint("BOTTOM", playerFrame, -90, 250)
playerFrame.player3PPBetTitle:SetJustifyH("CENTER")
playerFrame.player3PPBetTitle:SetText("PP")
playerFrame.player3PPBetTitle:SetFont("Fonts\\FRIZQT__.TTF", 15, "OUTLINE")
playerFrame.player3PPBetTitle:Hide()
-- Perfect Pairs Amount
player3PPBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3PPBetAmount:SetPoint("CENTER", playerFrame, -51, -35)
player3PPBetAmount:SetJustifyH("CENTER")
player3PPBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- 21+3
playerFrame.player3213BetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3213BetTitle:SetPoint("BOTTOM", playerFrame, 109, 250)
playerFrame.player3213BetTitle:SetJustifyH("CENTER")
playerFrame.player3213BetTitle:SetText("21+3")
playerFrame.player3213BetTitle:SetFont("Fonts\\FRIZQT__.TTF", 15, "OUTLINE")
playerFrame.player3213BetTitle:Hide()
-- 21+3 Amount
player3213BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3213BetAmount:SetPoint("CENTER", playerFrame, 67, -36)
player3213BetAmount:SetJustifyH("CENTER")
player3213BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Insurance Amount
playerFrame.player3InsuranceBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3InsuranceBetAmount:SetPoint("CENTER", playerFrame, 109, -305)
playerFrame.player3InsuranceBetAmount:SetJustifyH("CENTER")
playerFrame.player3InsuranceBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
-- Player Name
playerFrame.player3Name = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3Name:SetPoint("BOTTOM", playerFrame, 0, 116)
playerFrame.player3Name:SetText("Seat Empty")
playerFrame.player3Name:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
-- Insurance
playerFrame.player3InsuranceTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3InsuranceTitle:SetPoint("BOTTOM", playerFrame, 0, 34)
playerFrame.player3InsuranceTitle:SetText("Insurance")
playerFrame.player3InsuranceTitle:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
playerFrame.player3InsuranceTitle:Hide()
-- Insurance (if available)
playerFrame.player3InsuranceSubtitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3InsuranceSubtitle:SetPoint("BOTTOM", playerFrame, 0, 24)
playerFrame.player3InsuranceSubtitle:SetText("(if available)")
playerFrame.player3InsuranceSubtitle:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player3InsuranceSubtitle:Hide()
-- Session Win Update
playerFrame.player3WinningsUpdate = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player3WinningsUpdate:SetPoint("BOTTOMLEFT", playerFrame, 270, 30) 
playerFrame.player3WinningsUpdate:SetText("")
playerFrame.player3WinningsUpdate:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
playerFrame.player3WinningsUpdate:SetTextColor(0.118, 0.839, 0.412)

-- Images for Player 3
-- Turn Arrow
playerFrame.player3TurnArrow = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3TurnArrow:SetSize(128, 128)
playerFrame.player3TurnArrow:SetPoint("CENTER", playerFrame, 109, -213)
playerFrame.player3TurnArrow:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\TurnArrow.tga")
playerFrame.player3TurnArrow:SetBlendMode("BLEND")
playerFrame.player3TurnArrow:SetDrawLayer("OVERLAY")
playerFrame.player3TurnArrow:Hide()
-- Main Bet
playerFrame.player3MainBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3MainBetCoins:SetSize(128, 128)
playerFrame.player3MainBetCoins:SetPoint("CENTER", playerFrame, 23, -90)
playerFrame.player3MainBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player3MainBetCoins:SetBlendMode("BLEND")
playerFrame.player3MainBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player3MainBetCoins:Hide()
-- Win
playerFrame.player3NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3NormalWinCoins:SetSize(128, 128)
playerFrame.player3NormalWinCoins:SetPoint("CENTER", playerFrame, 23, -90)
playerFrame.player3NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player3NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player3NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player3NormalWinCoins:Hide()
-- Split Hand 2 Bet
playerFrame.player3SplitHand2Coins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3SplitHand2Coins:SetSize(128, 128)
playerFrame.player3SplitHand2Coins:SetPoint("CENTER", playerFrame, 5, -85)
playerFrame.player3SplitHand2Coins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player3SplitHand2Coins:SetBlendMode("BLEND")
playerFrame.player3SplitHand2Coins:SetDrawLayer("OVERLAY")
playerFrame.player3SplitHand2Coins:Hide()
-- Split Double Hand 2 Bet
playerFrame.player3SplitHand2DoubleCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3SplitHand2DoubleCoins:SetSize(128, 128)
playerFrame.player3SplitHand2DoubleCoins:SetPoint("CENTER", playerFrame, 2, -94)
playerFrame.player3SplitHand2DoubleCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player3SplitHand2DoubleCoins:SetBlendMode("BLEND")
playerFrame.player3SplitHand2DoubleCoins:SetDrawLayer("OVERLAY")
playerFrame.player3SplitHand2DoubleCoins:Hide()
-- Split Win Hand 2
playerFrame.player3SplitHand2NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3SplitHand2NormalWinCoins:SetSize(128, 128)
playerFrame.player3SplitHand2NormalWinCoins:SetPoint("CENTER", playerFrame, 2, -94)
playerFrame.player3SplitHand2NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player3SplitHand2NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player3SplitHand2NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player3SplitHand2NormalWinCoins:Hide()
-- Split Hand 1 Bet
playerFrame.player3SplitHand1Coins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3SplitHand1Coins:SetSize(128, 128)
playerFrame.player3SplitHand1Coins:SetPoint("CENTER", playerFrame, 40, -85)
playerFrame.player3SplitHand1Coins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player3SplitHand1Coins:SetBlendMode("BLEND")
playerFrame.player3SplitHand1Coins:SetDrawLayer("OVERLAY")
playerFrame.player3SplitHand1Coins:Hide()
-- Split Double Hand 1 Bet
playerFrame.player3SplitHand1DoubleCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3SplitHand1DoubleCoins:SetSize(128, 128)
playerFrame.player3SplitHand1DoubleCoins:SetPoint("CENTER", playerFrame, 45, -94)
playerFrame.player3SplitHand1DoubleCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player3SplitHand1DoubleCoins:SetBlendMode("BLEND")
playerFrame.player3SplitHand1DoubleCoins:SetDrawLayer("OVERLAY")
playerFrame.player3SplitHand1DoubleCoins:Hide()
-- Split Win Hand 1
playerFrame.player3SplitHand1NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3SplitHand1NormalWinCoins:SetSize(128, 128)
playerFrame.player3SplitHand1NormalWinCoins:SetPoint("CENTER", playerFrame, 45, -94)
playerFrame.player3SplitHand1NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player3SplitHand1NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player3SplitHand1NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player3SplitHand1NormalWinCoins:Hide()
-- Blackjack Win
playerFrame.player3BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3BJWinCoins:SetSize(128, 128)
playerFrame.player3BJWinCoins:SetPoint("CENTER", playerFrame, 23, -90)
playerFrame.player3BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player3BJWinCoins:SetBlendMode("BLEND")
playerFrame.player3BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player3BJWinCoins:Hide()
-- Split BJ Win Hand 2
playerFrame.player3SplitHand2BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3SplitHand2BJWinCoins:SetSize(128, 128)
playerFrame.player3SplitHand2BJWinCoins:SetPoint("CENTER", playerFrame, 2, -94)
playerFrame.player3SplitHand2BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player3SplitHand2BJWinCoins:SetBlendMode("BLEND")
playerFrame.player3SplitHand2BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player3SplitHand2BJWinCoins:Hide()
-- Split BJ Win Hand 1
playerFrame.player3SplitHand1BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3SplitHand1BJWinCoins:SetSize(128, 128)
playerFrame.player3SplitHand1BJWinCoins:SetPoint("CENTER", playerFrame, 45, -94)
playerFrame.player3SplitHand1BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player3SplitHand1BJWinCoins:SetBlendMode("BLEND")
playerFrame.player3SplitHand1BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player3SplitHand1BJWinCoins:Hide()
-- Double Bet
playerFrame.player3DoubleBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3DoubleBetCoins:SetSize(128, 128)
playerFrame.player3DoubleBetCoins:SetPoint("CENTER", playerFrame, 23, -90)
playerFrame.player3DoubleBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player3DoubleBetCoins:SetBlendMode("BLEND")
playerFrame.player3DoubleBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player3DoubleBetCoins:Hide()
-- PP Bet
playerFrame.player3PPBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3PPBetCoins:SetSize(128, 128)
playerFrame.player3PPBetCoins:SetPoint("CENTER", playerFrame, -47, -55)
playerFrame.player3PPBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsHalfBet.tga")
playerFrame.player3PPBetCoins:SetBlendMode("BLEND")
playerFrame.player3PPBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player3PPBetCoins:Hide()
-- 21+3 Bet
playerFrame.player3213BetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3213BetCoins:SetSize(128, 128)
playerFrame.player3213BetCoins:SetPoint("CENTER", playerFrame, 72, -56)
playerFrame.player3213BetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsHalfBet.tga")
playerFrame.player3213BetCoins:SetBlendMode("BLEND")
playerFrame.player3213BetCoins:SetDrawLayer("OVERLAY")
playerFrame.player3213BetCoins:Hide()
-- PP Win
playerFrame.player3PPWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3PPWinCoins:SetSize(128, 128)
playerFrame.player3PPWinCoins:SetPoint("CENTER", playerFrame, -35, -51)
playerFrame.player3PPWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player3PPWinCoins:SetBlendMode("BLEND")
playerFrame.player3PPWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player3PPWinCoins:Hide()
-- 21+3 Win
playerFrame.player3213WinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player3213WinCoins:SetSize(128, 128)
playerFrame.player3213WinCoins:SetPoint("CENTER", playerFrame, 83, -51)
playerFrame.player3213WinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player3213WinCoins:SetBlendMode("BLEND")
playerFrame.player3213WinCoins:SetDrawLayer("OVERLAY")
playerFrame.player3213WinCoins:Hide()
-- Insurance YES for Player 3
player3InsuranceYesIcon = playerFrame:CreateTexture(nil, "OVERLAY")
player3InsuranceYesIcon:SetSize(24, 24)
player3InsuranceYesIcon:SetPoint("CENTER", playerFrame, 105, -324)
player3InsuranceYesIcon:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\insuranceYes.tga")
player3InsuranceYesIcon:SetDrawLayer("OVERLAY")
player3InsuranceYesIcon:Hide()
-- Insurance NO for Player 3
player3InsuranceNoIcon = playerFrame:CreateTexture(nil, "OVERLAY")
player3InsuranceNoIcon:SetSize(24, 24)
player3InsuranceNoIcon:SetPoint("CENTER", playerFrame, 105, -324)
player3InsuranceNoIcon:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\insuranceNo.tga")
player3InsuranceNoIcon:SetDrawLayer("OVERLAY")
player3InsuranceNoIcon:Hide()

-- BJ Win Coins
function player3PlaceCoinsBJWin(message)
    playerFrame.player3MainBetCoins:Hide()
    playerFrame.player3BJWinCoins:Show()
end

-- Regular Win Coins
function player3PlaceCoinsRegularWin(message)
    playerFrame.player3MainBetCoins:Hide()
    playerFrame.player3DoubleBetCoins:Show()
end

-- Main Bet Coins
function player3PlaceCoinsMainBet(message)
    playerFrame.player3MainBetCoins:Show()
end

-- Double Bet Coins
function player3PlaceCoinsDoubleBet(message)
    playerFrame.player3MainBetCoins:Hide()
    playerFrame.player3DoubleBetCoins:Show()
end

-- Function to handle Player 3 Main Bet Text
function player3PlaceTextMainBet(message)
    player3HistoryMainBet = string.match(message, "(%d+)G")

        if player3HistoryMainBet then
            player3MainBetAmount:SetText(player3HistoryMainBet .. " G")
            player3MainBetAmount:Show()

            if playerName == unitName3 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName3]
                    player3totalBetAmount = player3totalBetAmount + tonumber(player3HistoryMainBet)
                    bankingInfo.totalWagered = player3totalBetAmount
                end
            end

            historyFrame.player3totalWageredAmount:SetText(player3totalBetAmount .. " G")

        else
    end
end

-- Player 3 Split Hand Bet Text
function player3SplitHand1BetText(Amount)
    player3MainBetAmount:Hide()
    player3MainBetAmount:SetText("")
    player3SplitH1BetAmount:SetText(Amount .. " G")
    player3SplitH1BetAmount:Show()
    player3SplitH2BetAmount:SetText(Amount .. " G")
    player3SplitH2BetAmount:Show()
end

-- Player 3 Split Bet Image
function player3PlaceSplitBet(message)
    playerFrame.player3MainBetCoins:Hide()
    playerFrame.player3SplitHand1Coins:Show()
    playerFrame.player3SplitHand2Coins:Show()
end

-- Player 3 Place Initial Card Images
function player3PlaceSplitCards(message)

    -- Players: 3
    if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
        drawnCards[1]:Hide()
        drawnCards[3]:Hide()
        player3cardName1 = dealtCards[1]
        player3cardName2 = dealtCards[3]
        turn = 8 -- Player 3: 2nd Card (Split H1)

    -- Players: 1, 3
    elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
        drawnCards[2]:Hide()
        drawnCards[5]:Hide()
        player3cardName1 = dealtCards[2]
        player3cardName2 = dealtCards[5]
        turn = 30 -- Player 3: 2nd Card (Split H1)
    -- Players: 2, 3
    elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
        drawnCards[2]:Hide()
        drawnCards[5]:Hide()
        player3cardName1 = dealtCards[2]
        player3cardName2 = dealtCards[5]
        turn = 30 -- Player 3: 2nd Card (Split H1)
    -- Players: 3, 4
    elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
        drawnCards[1]:Hide()
        drawnCards[4]:Hide()
        player3cardName1 = dealtCards[1]
        player3cardName2 = dealtCards[4]
        turn = 10 -- Player 3: 2nd Card (Split H1)
    -- Players: 3, 5
    elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
        drawnCards[1]:Hide()
        drawnCards[4]:Hide()
        player3cardName1 = dealtCards[1]
        player3cardName2 = dealtCards[4]
        turn = 10 -- Player 3: 2nd Card (Split H1)

    -- Players: 1, 2, 3
    elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
        drawnCards[3]:Hide()
        drawnCards[7]:Hide()
        player3cardName1 = dealtCards[3]
        player3cardName2 = dealtCards[7]
        turn = 52 -- Player 3: 2nd Card (Split H1)
    -- Players: 1, 3, 4
    elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
        drawnCards[2]:Hide()
        drawnCards[6]:Hide()
        player3cardName1 = dealtCards[2]
        player3cardName2 = dealtCards[6]
        turn = 32 -- Player 3: 2nd Card (Split H1)
    -- Players: 1, 3, 5
    elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
        drawnCards[2]:Hide()
        drawnCards[6]:Hide()
        player3cardName1 = dealtCards[2]
        player3cardName2 = dealtCards[6]
        turn = 32 -- Player 3: 2nd Card (Split H1)
    -- Players: 2, 3, 4
    elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
        drawnCards[2]:Hide()
        drawnCards[6]:Hide()
        player3cardName1 = dealtCards[2]
        player3cardName2 = dealtCards[6]
        turn = 32 -- Player 3: 2nd Card (Split H1)
    -- Players: 2, 3, 5
    elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
        drawnCards[2]:Hide()
        drawnCards[6]:Hide()
        player3cardName1 = dealtCards[2]
        player3cardName2 = dealtCards[6]
        turn = 32 -- Player 3: 2nd Card (Split H1)
    -- Players: 3, 4, 5
    elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
        drawnCards[1]:Hide()
        drawnCards[5]:Hide()
        player3cardName1 = dealtCards[1]
        player3cardName2 = dealtCards[5]
        turn = 12 -- Player 3: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4
    elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
        drawnCards[3]:Hide()
        drawnCards[8]:Hide()
        player3cardName1 = dealtCards[3]
        player3cardName2 = dealtCards[8]
        turn = 54 -- Player 3: 2nd Card (Split H1)
    -- Players: 1, 2, 3, 5
    elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
        drawnCards[3]:Hide()
        drawnCards[8]:Hide()
        player3cardName1 = dealtCards[3]
        player3cardName2 = dealtCards[8]
        turn = 54 -- Player 3: 2nd Card (Split H1)
    -- Players: 1, 3, 4, 5
    elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
        drawnCards[2]:Hide()
        drawnCards[7]:Hide()
        player3cardName1 = dealtCards[2]
        player3cardName2 = dealtCards[7]
        turn = 34 -- Player 3: 2nd Card (Split H1)
    -- Players: 2, 3, 4, 5
    elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
        drawnCards[2]:Hide()
        drawnCards[7]:Hide()
        player3cardName1 = dealtCards[2]
        player3cardName2 = dealtCards[7]
        turn = 34 -- Player 3: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4, 5
    elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
        drawnCards[3]:Hide()
        drawnCards[9]:Hide()
        player3cardName1 = dealtCards[3]
        player3cardName2 = dealtCards[9]
        turn = 56 -- Player 3: 2nd Card (Split H1)

    end

    player3cardImageFile1 = nil
    player3cardImageFile2 = nil

    for filename, cardDescription in pairs(cardNames) do
        if cardDescription == player3cardName1 then
            player3cardImageFile1 = filename
            break
        end
    end

    for filename, cardDescription in pairs(cardNames) do
        if cardDescription == player3cardName2 then
            player3cardImageFile2 = filename
            break
        end
    end

    player3NewCardImage1 = CreateFrame("Frame", nil, playerFrame)
    player3NewCardImage1:SetSize(32, 64)
    player3NewCardImage1:SetPoint("BOTTOM", playerFrame, 25, 309)
    player3NewCardImage1.texture = player3NewCardImage1:CreateTexture()
    player3NewCardImage1.texture:SetAllPoints()
    player3NewCardImage1.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3cardImageFile1)
    player3NewCardImage1:Show()

    player3NewCardImage2 = CreateFrame("Frame", nil, playerFrame)
    player3NewCardImage2:SetSize(32, 64)
    player3NewCardImage2:SetPoint("BOTTOM", playerFrame, -17, 309)
    player3NewCardImage2.texture = player3NewCardImage2:CreateTexture()
    player3NewCardImage2.texture:SetAllPoints()
    player3NewCardImage2.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3cardImageFile2)
    player3NewCardImage2:Show()

end

-- Player 3 Split Function
function player3HandleSplit(message)
    player3PlaceSplitBet()
    player3MainBetAmountValue = tonumber(string.match(player3MainBetAmount:GetText(), "%d+"))
    if player3MainBetAmountValue then
        player3SplitHand1BetText(player3MainBetAmountValue)
    end 

    player3PlaceSplitCards()

    -- A,A
    if playerFrame.player3CardTotalText:GetText() == "2 or 12" then
        playerFrame.player3SplitHand1CardTotalText:SetText("1 or 11")
        playerFrame.player3SplitHand1CardTotalText:Show()
        playerFrame.player3SplitHand2CardTotalText:SetText("1 or 11")
        playerFrame.player3SplitHand2CardTotalText:Show()
    -- 2,2
    elseif playerFrame.player3CardTotalText:GetText() == "4" then
        playerFrame.player3SplitHand1CardTotalText:SetText("2")
        playerFrame.player3SplitHand1CardTotalText:Show()
        playerFrame.player3SplitHand2CardTotalText:SetText("2")
        playerFrame.player3SplitHand2CardTotalText:Show()
    -- 3,3
    elseif playerFrame.player3CardTotalText:GetText() == "6" then
        playerFrame.player3SplitHand1CardTotalText:SetText("3")
        playerFrame.player3SplitHand1CardTotalText:Show()
        playerFrame.player3SplitHand2CardTotalText:SetText("3")
        playerFrame.player3SplitHand2CardTotalText:Show()
    -- 4,4
    elseif playerFrame.player3CardTotalText:GetText() == "8" then
        playerFrame.player3SplitHand1CardTotalText:SetText("4")
        playerFrame.player3SplitHand1CardTotalText:Show()
        playerFrame.player3SplitHand2CardTotalText:SetText("4")
        playerFrame.player3SplitHand2CardTotalText:Show()
    -- 5,5
    elseif playerFrame.player3CardTotalText:GetText() == "10" then
        playerFrame.player3SplitHand1CardTotalText:SetText("5")
        playerFrame.player3SplitHand1CardTotalText:Show()
        playerFrame.player3SplitHand2CardTotalText:SetText("5")
        playerFrame.player3SplitHand2CardTotalText:Show()
    -- 6,6
    elseif playerFrame.player3CardTotalText:GetText() == "12" then
        playerFrame.player3SplitHand1CardTotalText:SetText("6")
        playerFrame.player3SplitHand1CardTotalText:Show()
        playerFrame.player3SplitHand2CardTotalText:SetText("6")
        playerFrame.player3SplitHand2CardTotalText:Show()
    -- 7,7
    elseif playerFrame.player3CardTotalText:GetText() == "14" then
        playerFrame.player3SplitHand1CardTotalText:SetText("7")
        playerFrame.player3SplitHand1CardTotalText:Show()
        playerFrame.player3SplitHand2CardTotalText:SetText("7")
        playerFrame.player3SplitHand2CardTotalText:Show()
    -- 8,8
    elseif playerFrame.player3CardTotalText:GetText() == "16" then
        playerFrame.player3SplitHand1CardTotalText:SetText("8")
        playerFrame.player3SplitHand1CardTotalText:Show()
        playerFrame.player3SplitHand2CardTotalText:SetText("8")
        playerFrame.player3SplitHand2CardTotalText:Show()
    -- 9,9
    elseif playerFrame.player3CardTotalText:GetText() == "18" then
        playerFrame.player3SplitHand1CardTotalText:SetText("9")
        playerFrame.player3SplitHand1CardTotalText:Show()
        playerFrame.player3SplitHand2CardTotalText:SetText("9")
        playerFrame.player3SplitHand2CardTotalText:Show()
    -- 10,10
    elseif playerFrame.player3CardTotalText:GetText() == "20" then
        playerFrame.player3SplitHand1CardTotalText:SetText("10")
        playerFrame.player3SplitHand1CardTotalText:Show()
        playerFrame.player3SplitHand2CardTotalText:SetText("10")
        playerFrame.player3SplitHand2CardTotalText:Show()
    end

    playerFrame.player3CardTotalText:SetText("")
    playerFrame.player3CardTotalText:Hide()
    
    if playerName == unitName3 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player3totalBetAmount = player3totalBetAmount + tonumber(player3MainBetAmountValue)
            bankingInfo.totalWagered = player3totalBetAmount
            player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(player3MainBetAmountValue)
            bankingInfo.bankrollTable = player3TotalBankrollAmount
        end
    end

    historyFrame.player3totalWageredAmount:SetText(player3totalBetAmount .. " G")
    bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
    cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

    player3SplitToggle = true

    if player3dealtCardsFrame:IsShown() then
        player3dealtCardsFrame:Hide()
        player3dealtCardsFrame.playerCardsButton:Hide()
        player3dealtCardsFrameSplitH1:Show()
        player3dealtCardsFrameSplitH1.playerH1CardsButton:Show()
        player3dealtCardsFrameSplitH1.playerH2CardsButton:Show()
    end

end

-- Function to handle Player 3 PP Bet Image
function player3PlaceCoinsPPBet(message)
    playerFrame.player3PPBetCoins:Show()
end

-- Function to handle Player 3 PP Bet Text
function player3PlaceTextPPBet(message)
    player3HistoryPPBet = string.match(message, "(%d+)G")

        if player3HistoryPPBet then
            player3PPBetAmount:SetText(player3HistoryPPBet .. " G")
            player3PPBetAmount:Show()

            if playerName == unitName3 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName3]
                    player3totalBetAmount = player3totalBetAmount + tonumber(player3HistoryPPBet)
                    bankingInfo.totalWagered = player3totalBetAmount
                end
            end

            historyFrame.player3totalWageredAmount:SetText(player3totalBetAmount .. " G")

        else
    end
end

-- Function to handle Player 3 21+3 Bet Image
function player3PlaceCoins213Bet(message)
    playerFrame.player3213BetCoins:Show()
end

-- Function to handle Player 3 21+3 Bet Text
function player3PlaceText213Bet(message)
    player3History213Bet = string.match(message, "(%d+)G")

        if player3History213Bet then
            player3213BetAmount:SetText(player3History213Bet .. " G")
            player3213BetAmount:Show()

            if playerName == unitName3 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName3]
                    player3totalBetAmount = player3totalBetAmount + tonumber(player3History213Bet)
                    bankingInfo.totalWagered = player3totalBetAmount
                end
            end

            historyFrame.player3totalWageredAmount:SetText(player3totalBetAmount .. " G")

        else
    end
end

function player3PreloadBet()
    
    player3MainBet = tonumber(player3PreloadEditBoxMainBet:GetText()) or 0
    player3PPBet = tonumber(player3PreloadEditBoxPPBet:GetText()) or 0
    player3213Bet = tonumber(player3PreloadEditBox213Bet:GetText()) or 0

    player3TotalRebetAmount = player3MainBet + player3PPBet + player3213Bet

    player3currentBankroll = tonumber(string.match(bankrollFrame.player3TotalBankrollTableDisplay:GetText(), "%d+"))

    if player3currentBankroll - player3TotalRebetAmount < 0 then
        print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
    else
        player3Threshold = minBetMain - 1
        if player3MainBet <= player3Threshold then
            print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
        else
            if player3MainBet and player3MainBet >= minBetMain and player3MainBet <= maxBetMain then
                PlaySoundFile(soundFilePaths[33])
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P3] PIacing a " ..player3MainBet.. "G main bet.", "RAID")
                -- Disable the edit box and button
                player3PreloadEditBoxMainBet:SetFocus(false)
                player3PreloadEditBoxMainBet:ClearFocus()
                player3MainBetEditBox:SetText("")
                player3MainBetEditBox:SetText(player3MainBet)
                player3MainBetEditBox:SetFocus(false)
                player3MainBetEditBox:ClearFocus()
                player3MainBetEditBox:Disable()
                player3ConfirmMainBetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(player3MainBet)
                    bankingInfo.bankrollTable = player3TotalBankrollAmount
                end
            end

            if player3PPBet and player3PPBet >= minBetPP and player3PPBet <= maxBetPP then
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P3] PIacing a " ..player3PPBet.. "G side bet on Perfect Pairs.", "RAID")
                -- Disable the edit box and button
                player3PreloadEditBoxPPBet:SetFocus(false)
                player3PreloadEditBoxPPBet:ClearFocus()
                player3PPBetEditBox:SetText("")
                player3PPBetEditBox:SetText(player3PPBet)
                player3PPBetEditBox:SetFocus(false)
                player3PPBetEditBox:ClearFocus()
                player3PPBetEditBox:Disable()
                player3ConfirmPPBetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(player3PPBet)
                    bankingInfo.bankrollTable = player3TotalBankrollAmount
                end
            end

            if player3213Bet and player3213Bet >= minBet213 and player3213Bet <= maxBet213 then
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P3] PIacing a " ..player3213Bet.. "G side bet on 21+3.", "RAID")
                -- Disable the edit box and button
                player3PreloadEditBox213Bet:SetFocus(false)
                player3PreloadEditBox213Bet:ClearFocus()
                player3213BetEditBox:SetText("")
                player3213BetEditBox:SetText(player3213Bet)
                player3213BetEditBox:SetFocus(false)
                player3213BetEditBox:ClearFocus()
                player3213BetEditBox:Disable()
                player3Confirm213BetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(player3213Bet)
                    bankingInfo.bankrollTable = player3TotalBankrollAmount
                end
            end
            
            player3PreloadBetButton:Disable()

        end

        bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

    end

end

-- Function to handle the Player 1 Main "Bet" button click
function player3ConfirmMainBetClick()
    player3MainBet = tonumber(player3MainBetEditBox:GetText())
    player3currentBankroll = tonumber(string.match(bankrollFrame.player3TotalBankrollTableDisplay:GetText(), "%d+"))

    if player3MainBet and player3MainBet >= minBetMain and player3MainBet <= maxBetMain then
        if player3currentBankroll - player3MainBet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            -- Valid bet amount, send the message with the bet
            SendChatMessage("[P3] PIacing a " ..player3MainBet.. "G main bet.", "RAID")
            -- Disable the edit box and button
            player3MainBetEditBox:SetFocus(false)
            player3MainBetEditBox:ClearFocus()
            player3MainBetEditBox:Disable()
            player3ConfirmMainBetButton:Disable()

            player3PreloadBetButton:Disable()

            PlaySoundFile(soundFilePaths[33]) 

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(player3MainBet)
                bankingInfo.bankrollTable = player3TotalBankrollAmount
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBetMain .. "G and " .. maxBetMain .. "G.")
    end

end

-- Function to handle the Player 1 PP "Bet" button click
function player3ConfirmPPBetClick()
    player3PPBet = tonumber(player3PPBetEditBox:GetText()) -- Get the entered bet amount
    player3currentBankroll = tonumber(string.match(bankrollFrame.player3TotalBankrollTableDisplay:GetText(), "%d+"))

    if player3PPBet and player3PPBet >= minBetPP and player3PPBet <= maxBetPP then
        if player3currentBankroll - player3PPBet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            if not player3Active then
                print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
            else
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P3] PIacing a " ..player3PPBet.. "G side bet on Perfect Pairs.", "RAID")
                -- Disable the edit box and button
                player3PPBetEditBox:SetFocus(false)
                player3PPBetEditBox:ClearFocus()
                player3PPBetEditBox:Disable()
                player3ConfirmPPBetButton:Disable()

                player3PreloadBetButton:Disable()

                PlaySoundFile(soundFilePaths[33])

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(player3PPBet)
                    bankingInfo.bankrollTable = player3TotalBankrollAmount
                end

                bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
                cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

            end
        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBetPP .. "G and " .. maxBetPP .. "G.")
    end

end

-- Function to handle the Player 1 21+3 "Bet" button click
function player3Confirm213BetClick()
    player3213Bet = tonumber(player3213BetEditBox:GetText()) -- Get the entered bet amount
    player3currentBankroll = tonumber(string.match(bankrollFrame.player3TotalBankrollTableDisplay:GetText(), "%d+"))

    if player3213Bet and player3213Bet >= minBet213 and player3213Bet <= maxBet213 then
        if player3currentBankroll - player3213Bet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            if not player3Active then
                print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
            else
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P3] PIacing a " ..player3213Bet.. "G side bet on 21+3.", "RAID")
                -- Disable the edit box and button
                player3213BetEditBox:SetFocus(false)
                player3213BetEditBox:ClearFocus()
                player3213BetEditBox:Disable()
                player3Confirm213BetButton:Disable()

                player3PreloadBetButton:Disable()

                PlaySoundFile(soundFilePaths[33])

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(player3213Bet)
                    bankingInfo.bankrollTable = player3TotalBankrollAmount
                end

                bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
                cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

            end
        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBet213 .. "G and " .. maxBet213 .. "G.")
    end
 
end

-- Player 3 Main "Bet" button
player3ConfirmMainBetButton:SetScript("OnClick", player3ConfirmMainBetClick)

-- Player 3 PP "Bet" button
player3ConfirmPPBetButton:SetScript("OnClick", player3ConfirmPPBetClick)

-- Player 3 21+3 "Bet" button
player3Confirm213BetButton:SetScript("OnClick", player3Confirm213BetClick)

-- Player 3 "Bet All" Preload button
player3PreloadBetButton:SetScript("OnClick", player3PreloadBet)

function player3resetRaidChannel()
    if playerName == unitName3 then
        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/raid", chatFrame)
        
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:SetText("")
        editBox:Insert("/raid")
        
        ChatEdit_SendText(editBox)
        ChatEdit_DeactivateChat(editBox)
    else
        print("")
    end
end

player3HotstreakImage1 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage1:SetSize(36, 36)
player3HotstreakImage1:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak1.tga")
player3HotstreakImage1:SetDrawLayer("OVERLAY")
player3HotstreakImage1:Hide()

player3HotstreakImage2 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage2:SetSize(36, 36)
player3HotstreakImage2:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak2.tga")
player3HotstreakImage2:SetDrawLayer("OVERLAY")
player3HotstreakImage2:Hide()

player3HotstreakImage3 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage3:SetSize(36, 36)
player3HotstreakImage3:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak3.tga")
player3HotstreakImage3:SetDrawLayer("OVERLAY")
player3HotstreakImage3:Hide()

player3HotstreakImage4 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage4:SetSize(36, 36)
player3HotstreakImage4:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak4.tga")
player3HotstreakImage4:SetDrawLayer("OVERLAY")
player3HotstreakImage4:Hide()

player3HotstreakImage5 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage5:SetSize(36, 36)
player3HotstreakImage5:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak5.tga")
player3HotstreakImage5:SetDrawLayer("OVERLAY")
player3HotstreakImage5:Hide()

player3HotstreakImage6 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage6:SetSize(36, 36)
player3HotstreakImage6:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak6.tga")
player3HotstreakImage6:SetDrawLayer("OVERLAY")
player3HotstreakImage6:Hide()

player3HotstreakImage7 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage7:SetSize(36, 36)
player3HotstreakImage7:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak7.tga")
player3HotstreakImage7:SetDrawLayer("OVERLAY")
player3HotstreakImage7:Hide()

player3HotstreakImage8 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage8:SetSize(36, 36)
player3HotstreakImage8:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage8:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak8.tga")
player3HotstreakImage8:SetDrawLayer("OVERLAY")
player3HotstreakImage8:Hide()

player3HotstreakImage9 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage9:SetSize(36, 36)
player3HotstreakImage9:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage9:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak9.tga")
player3HotstreakImage9:SetDrawLayer("OVERLAY")
player3HotstreakImage9:Hide()

player3HotstreakImage10 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage10:SetSize(36, 36)
player3HotstreakImage10:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage10:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak10.tga")
player3HotstreakImage10:SetDrawLayer("OVERLAY")
player3HotstreakImage10:Hide()

player3HotstreakImage11 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage11:SetSize(36, 36)
player3HotstreakImage11:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage11:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak11.tga")
player3HotstreakImage11:SetDrawLayer("OVERLAY")
player3HotstreakImage11:Hide()

player3HotstreakImage12 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage12:SetSize(36, 36)
player3HotstreakImage12:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage12:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak12.tga")
player3HotstreakImage12:SetDrawLayer("OVERLAY")
player3HotstreakImage12:Hide()

player3HotstreakImage13 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage13:SetSize(36, 36)
player3HotstreakImage13:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage13:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak13.tga")
player3HotstreakImage13:SetDrawLayer("OVERLAY")
player3HotstreakImage13:Hide()

player3HotstreakImage14 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage14:SetSize(36, 36)
player3HotstreakImage14:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage14:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak14.tga")
player3HotstreakImage14:SetDrawLayer("OVERLAY")
player3HotstreakImage14:Hide()

player3HotstreakImage15 = playerFrame:CreateTexture(nil, "OVERLAY")
player3HotstreakImage15:SetSize(36, 36)
player3HotstreakImage15:SetPoint("CENTER", playerFrame, -83, -276)
player3HotstreakImage15:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak15.tga")
player3HotstreakImage15:SetDrawLayer("OVERLAY")
player3HotstreakImage15:Hide()

function player3HotStreakCheck()
    if player3Hotstreak == 0 then
        player3HotstreakImage1:Hide()
        player3HotstreakImage2:Hide()
        player3HotstreakImage3:Hide()
        player3HotstreakImage4:Hide()
        player3HotstreakImage5:Hide()
        player3HotstreakImage6:Hide()
        player3HotstreakImage7:Hide()
        player3HotstreakImage8:Hide()
        player3HotstreakImage9:Hide()
        player3HotstreakImage10:Hide()
        player3HotstreakImage11:Hide()
        player3HotstreakImage12:Hide()
        player3HotstreakImage13:Hide()
        player3HotstreakImage14:Hide()
        player3HotstreakImage15:Hide()
    elseif player3Hotstreak == 1 then
        player3HotstreakImage1:Show()
    elseif player3Hotstreak == 2 then
        player3HotstreakImage1:Hide()
        player3HotstreakImage2:Show()
    elseif player3Hotstreak == 3 then
        player3HotstreakImage1:Hide()
        player3HotstreakImage2:Hide()
        player3HotstreakImage3:Show()
    elseif player3Hotstreak == 4 then
        player3HotstreakImage2:Hide()
        player3HotstreakImage3:Hide()
        player3HotstreakImage4:Show()
    elseif player3Hotstreak == 5 then
        player3HotstreakImage3:Hide()
        player3HotstreakImage4:Hide()
        player3HotstreakImage5:Show()
    elseif player3Hotstreak == 6 then
        player3HotstreakImage4:Hide()
        player3HotstreakImage5:Hide()
        player3HotstreakImage6:Show()
    elseif player3Hotstreak == 7 then
        player3HotstreakImage5:Hide()
        player3HotstreakImage6:Hide()
        player3HotstreakImage7:Show()
    elseif player3Hotstreak == 8 then
        player3HotstreakImage6:Hide()
        player3HotstreakImage7:Hide()
        player3HotstreakImage8:Show()
    elseif player3Hotstreak == 9 then
        player3HotstreakImage7:Hide()
        player3HotstreakImage8:Hide()
        player3HotstreakImage9:Show()
    elseif player3Hotstreak == 10 then
        player3HotstreakImage8:Hide()
        player3HotstreakImage9:Hide()
        player3HotstreakImage10:Show()
    elseif player3Hotstreak == 11 then
        player3HotstreakImage9:Hide()
        player3HotstreakImage10:Hide()
        player3HotstreakImage11:Show()
    elseif player3Hotstreak == 12 then
        player3HotstreakImage10:Hide()
        player3HotstreakImage11:Hide()
        player3HotstreakImage12:Show()
    elseif player3Hotstreak == 13 then
        player3HotstreakImage11:Hide()
        player3HotstreakImage12:Hide()
        player3HotstreakImage13:Show()
    elseif player3Hotstreak == 14 then
        player3HotstreakImage12:Hide()
        player3HotstreakImage13:Hide()
        player3HotstreakImage14:Show()
    elseif player3Hotstreak == 15 then
        player3HotstreakImage13:Hide()
        player3HotstreakImage14:Hide()
        player3HotstreakImage15:Show()
    end
end

-- Function to handle Player 3 PP Win Image
function player3PlaceBetsPPWin(message)
    playerFrame.player3PPBetCoins:Hide()
    playerFrame.player3PPWinCoins:Show()
    player3PPBetAmount:SetPoint("CENTER", playerFrame, -51, -18)
end

-- Function to handle Player 3 21+3 Win Image
function player3PlaceBets213Win(message)
    playerFrame.player3213BetCoins:Hide()
    playerFrame.player3213WinCoins:Show()
    player3213BetAmount:SetPoint("CENTER", playerFrame, 67, -19)
end

function player3MixedPairWin(message)

    if playerName == unitName3 then
        player3PPBetAmountValue = tonumber(string.match(player3PPBetEditBox:GetText(), "%d+"))
        if player3PPBetAmountValue then
            player3NewPPAmount = player3PPBetAmountValue * mixedPairPayoutReturn
            player3PPBetAmount:SetText(player3NewPPAmount .. " G")
            player3PPBetAmount:SetTextColor(0, 1, 0)

            player3PPProfitvalue = player3NewPPAmount - player3PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player3totalWin = player3totalWin + tonumber(player3PPProfitvalue)
                    bankingInfo.totalWon = player3totalWin
                    player3totalProfit = player3totalProfit + tonumber(player3PPProfitvalue)
                    bankingInfo.totalProfit = player3totalProfit
                    player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3NewPPAmount)
                    bankingInfo.bankrollTable = player3TotalBankrollAmount
                end

            historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
            historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
            if player3totalProfit >= 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        end
    else
        player3PPBetAmountValue = tonumber(string.match(player3PPBetAmount:GetText(), "%d+"))
        if player3PPBetAmountValue then
            player3NewPPAmount = player3PPBetAmountValue * mixedPairPayoutReturn
            player3PPBetAmount:SetText(player3NewPPAmount .. " G")
            player3PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player3PlaceBetsPPWin()
    player3PPSideBetWin = true

    player3SessionWin = player3SessionWin + tonumber(player3NewPPAmount)

end

function player3ColouredPairWin(message)

    if playerName == unitName3 then
        player3PPBetAmountValue = tonumber(string.match(player3PPBetEditBox:GetText(), "%d+"))
        if player3PPBetAmountValue then
            player3NewPPAmount = player3PPBetAmountValue * colouredPairPayoutReturn
            player3PPBetAmount:SetText(player3NewPPAmount .. " G")
            player3PPBetAmount:SetTextColor(0, 1, 0)

            player3PPProfitvalue = player3NewPPAmount - player3PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player3totalWin = player3totalWin + tonumber(player3PPProfitvalue)
                    bankingInfo.totalWon = player3totalWin
                    player3totalProfit = player3totalProfit + tonumber(player3PPProfitvalue)
                    bankingInfo.totalProfit = player3totalProfit
                    player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3NewPPAmount)
                    bankingInfo.bankrollTable = player3TotalBankrollAmount
                end

            historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
            historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
            if player3totalProfit >= 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        end
    else
        player3PPBetAmountValue = tonumber(string.match(player3PPBetAmount:GetText(), "%d+"))
        if player3PPBetAmountValue then
            player3NewPPAmount = player3PPBetAmountValue * colouredPairPayoutReturn
            player3PPBetAmount:SetText(player3NewPPAmount .. " G")
            player3PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player3PlaceBetsPPWin()
    player3PPSideBetWin = true

    player3SessionWin = player3SessionWin + tonumber(player3NewPPAmount)

end

function player3PerfectPairWin(message)

    if playerName == unitName3 then
        player3PPBetAmountValue = tonumber(string.match(player3PPBetEditBox:GetText(), "%d+"))
        if player3PPBetAmountValue then
            player3NewPPAmount = player3PPBetAmountValue * perfectPairPayoutReturn
            player3PPBetAmount:SetText(player3NewPPAmount .. " G")
            player3PPBetAmount:SetTextColor(0, 1, 0)

            player3PPProfitvalue = player3NewPPAmount - player3PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player3totalWin = player3totalWin + tonumber(player3PPProfitvalue)
                    bankingInfo.totalWon = player3totalWin
                    player3totalProfit = player3totalProfit + tonumber(player3PPProfitvalue)
                    bankingInfo.totalProfit = player3totalProfit
                    player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3NewPPAmount)
                    bankingInfo.bankrollTable = player3TotalBankrollAmount
                end

            historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
            historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
            if player3totalProfit >= 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        end
    else
        player3PPBetAmountValue = tonumber(string.match(player3PPBetAmount:GetText(), "%d+"))
        if player3PPBetAmountValue then
            player3NewPPAmount = player3PPBetAmountValue * perfectPairPayoutReturn
            player3PPBetAmount:SetText(player3NewPPAmount .. " G")
            player3PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player3PlaceBetsPPWin()
    player3PPSideBetWin = true

    player3SessionWin = player3SessionWin + tonumber(player3NewPPAmount)

end

function player3SuitedThreeOfAKindWin(message)

    if playerName == unitName3 then
        player3213BetAmountValue = tonumber(string.match(player3213BetEditBox:GetText(), "%d+"))
        if player3213BetAmountValue then
            player3New213Amount = player3213BetAmountValue * suitedThreeOfAKindPayoutReturn
            player3213BetAmount:SetText(player3New213Amount .. " G")
            player3213BetAmount:SetTextColor(0, 1, 0)

            player3213Profitvalue = player3New213Amount - player3213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3totalWin = player3totalWin + tonumber(player3213Profitvalue)
                bankingInfo.totalWon = player3totalWin
                player3totalProfit = player3totalProfit + tonumber(player3213Profitvalue)
                bankingInfo.totalProfit = player3totalProfit
                player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3New213Amount)
                bankingInfo.bankrollTable = player3TotalBankrollAmount
            end

            historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
            historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
            if player3totalProfit >= 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        end
    else
        player3213BetAmountValue = tonumber(string.match(player3213BetAmount:GetText(), "%d+"))
        if player3213BetAmountValue then
            player3New213Amount = player3213BetAmountValue * suitedThreeOfAKindPayoutReturn
            player3213BetAmount:SetText(player3New213Amount .. " G")
            player3213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player3PlaceBets213Win()
    player3213SideBetWin = true

    player3SessionWin = player3SessionWin + tonumber(player3New213Amount)

end

function player3StraightFlushWin(message)

    if playerName == unitName3 then
        player3213BetAmountValue = tonumber(string.match(player3213BetEditBox:GetText(), "%d+"))
        if player3213BetAmountValue then
            player3New213Amount = player3213BetAmountValue * straightFlushPayoutReturn
            player3213BetAmount:SetText(player3New213Amount .. " G")
            player3213BetAmount:SetTextColor(0, 1, 0)

            player3213Profitvalue = player3New213Amount - player3213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3totalWin = player3totalWin + tonumber(player3213Profitvalue)
                bankingInfo.totalWon = player3totalWin
                player3totalProfit = player3totalProfit + tonumber(player3213Profitvalue)
                bankingInfo.totalProfit = player3totalProfit
                player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3New213Amount)
                bankingInfo.bankrollTable = player3TotalBankrollAmount
            end

            historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
            historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
            if player3totalProfit >= 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        end
    else
        player3213BetAmountValue = tonumber(string.match(player3213BetAmount:GetText(), "%d+"))
        if player3213BetAmountValue then
            player3New213Amount = player3213BetAmountValue * straightFlushPayoutReturn
            player3213BetAmount:SetText(player3New213Amount .. " G")
            player3213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player3PlaceBets213Win()
    player3213SideBetWin = true

    player3SessionWin = player3SessionWin + tonumber(player3New213Amount)

end

function player3ThreeOfAKindWin(message)

    if playerName == unitName3 then
        player3213BetAmountValue = tonumber(string.match(player3213BetEditBox:GetText(), "%d+"))
        if player3213BetAmountValue then
            player3New213Amount = player3213BetAmountValue * threeOfAKindPayoutReturn
            player3213BetAmount:SetText(player3New213Amount .. " G")
            player3213BetAmount:SetTextColor(0, 1, 0)

            player3213Profitvalue = player3New213Amount - player3213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3totalWin = player3totalWin + tonumber(player3213Profitvalue)
                bankingInfo.totalWon = player3totalWin
                player3totalProfit = player3totalProfit + tonumber(player3213Profitvalue)
                bankingInfo.totalProfit = player3totalProfit
                player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3New213Amount)
                bankingInfo.bankrollTable = player3TotalBankrollAmount
            end

            historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
            historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
            if player3totalProfit >= 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        end
    else
        player3213BetAmountValue = tonumber(string.match(player3213BetAmount:GetText(), "%d+"))
        if player3213BetAmountValue then
            player3New213Amount = player3213BetAmountValue * threeOfAKindPayoutReturn
            player3213BetAmount:SetText(player3New213Amount .. " G")
            player3213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player3PlaceBets213Win()
    player3213SideBetWin = true

    player3SessionWin = player3SessionWin + tonumber(player3New213Amount)

end

function player3StraightWin(message)

    if playerName == unitName3 then
        player3213BetAmountValue = tonumber(string.match(player3213BetEditBox:GetText(), "%d+"))
        if player3213BetAmountValue then
            player3New213Amount = player3213BetAmountValue * straightPayoutReturn
            player3213BetAmount:SetText(player3New213Amount .. " G")
            player3213BetAmount:SetTextColor(0, 1, 0)

            player3213Profitvalue = player3New213Amount - player3213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3totalWin = player3totalWin + tonumber(player3213Profitvalue)
                bankingInfo.totalWon = player3totalWin
                player3totalProfit = player3totalProfit + tonumber(player3213Profitvalue)
                bankingInfo.totalProfit = player3totalProfit
                player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3New213Amount)
                bankingInfo.bankrollTable = player3TotalBankrollAmount
            end

            historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
            historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
            if player3totalProfit >= 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        end
    else
        player3213BetAmountValue = tonumber(string.match(player3213BetAmount:GetText(), "%d+"))
        if player3213BetAmountValue then
            player3New213Amount = player3213BetAmountValue * straightPayoutReturn
            player3213BetAmount:SetText(player3New213Amount .. " G")
            player3213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player3PlaceBets213Win()
    player3213SideBetWin = true

    player3SessionWin = player3SessionWin + tonumber(player3New213Amount)

end

function player3FlushWin(message)

    if playerName == unitName3 then
        player3213BetAmountValue = tonumber(string.match(player3213BetEditBox:GetText(), "%d+"))
        if player3213BetAmountValue then
            player3New213Amount = player3213BetAmountValue * flushPayoutReturn
            player3213BetAmount:SetText(player3New213Amount .. " G")
            player3213BetAmount:SetTextColor(0, 1, 0)

            player3213Profitvalue = player3New213Amount - player3213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3totalWin = player3totalWin + tonumber(player3213Profitvalue)
                bankingInfo.totalWon = player3totalWin
                player3totalProfit = player3totalProfit + tonumber(player3213Profitvalue)
                bankingInfo.totalProfit = player3totalProfit
                player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3New213Amount)
                bankingInfo.bankrollTable = player3TotalBankrollAmount
            end

            historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
            historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
            if player3totalProfit >= 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        end
    else
        player3213BetAmountValue = tonumber(string.match(player3213BetAmount:GetText(), "%d+"))
        if player3213BetAmountValue then
            player3New213Amount = player3213BetAmountValue * flushPayoutReturn
            player3213BetAmount:SetText(player3New213Amount .. " G")
            player3213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player3PlaceBets213Win()
    player3213SideBetWin = true

    player3SessionWin = player3SessionWin + tonumber(player3New213Amount)

end

function player3Loss()
    player3MainBetValue = tonumber(string.match(player3MainBetAmount:GetText(), "%d+"))
    if player3MainBetValue then
        
        if playerName == unitName3 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3totalLoss = player3totalLoss + tonumber(player3MainBetValue)
                bankingInfo.totalLost = player3totalLoss
                player3totalProfit = player3totalProfit - tonumber(player3MainBetValue)
                bankingInfo.totalProfit = player3totalProfit
            end
        end

        if player3totalProfit >= 0 then
            historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

        historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
        historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")

        player3PPBetText = player3PPBetAmount:GetText()

        if player3PPBetText and player3PPBetText ~= "" then
            player3PPBetAmountValue = tonumber(string.match(player3PPBetText, "%d+"))
            
            if player3PPBetAmountValue then
                if player3PPSideBetWin == false then

                    player3PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName3 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player3totalLoss = player3totalLoss + tonumber(player3PPBetAmountValue)
                            bankingInfo.totalLost = player3totalLoss
                            player3totalProfit = player3totalProfit - tonumber(player3PPBetAmountValue)
                            bankingInfo.totalProfit = player3totalProfit
                        end
                    end
            
                    if player3totalProfit >= 0 then
                        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end
            
                    historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")

                end
            end
        end

        player3213BetText = player3213BetAmount:GetText()

        if player3213BetText and player3213BetText ~= "" then
            player3213BetAmountValue = tonumber(string.match(player3213BetText, "%d+"))

            if player3213BetAmountValue then
                if player3213SideBetWin == false then

                    player3213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName3 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player3totalLoss = player3totalLoss + tonumber(player3213BetAmountValue)
                            bankingInfo.totalLost = player3totalLoss
                            player3totalProfit = player3totalProfit - tonumber(player3213BetAmountValue)
                            bankingInfo.totalProfit = player3totalProfit
                        end
                    end
            
                    if player3totalProfit >= 0 then
                        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end
            
                    historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")

                end
            end
        end
    end
end

function player3SplitH1Loss()
    player3SplitHand1BetAmountValue = tonumber(string.match(player3SplitH1BetAmount:GetText(), "%d+"))
    if player3SplitHand1BetAmountValue then

        if playerName == unitName3 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3totalLoss = player3totalLoss + tonumber(player3SplitHand1BetAmountValue)
                bankingInfo.totalLost = player3totalLoss
                player3totalProfit = player3totalProfit - tonumber(player3SplitHand1BetAmountValue)
                bankingInfo.totalProfit = player3totalProfit
            end
        end

        historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
        historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")

        if player3totalProfit >= 0 then
            historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

    end
end

function player3SplitH2Loss()
    player3SplitHand2BetAmountValue = tonumber(string.match(player3SplitH2BetAmount:GetText(), "%d+"))
    if player3SplitHand2BetAmountValue then

        if playerName == unitName3 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3totalLoss = player3totalLoss + tonumber(player3SplitHand2BetAmountValue)
                bankingInfo.totalLost = player3totalLoss
                player3totalProfit = player3totalProfit - tonumber(player3SplitHand2BetAmountValue)
                bankingInfo.totalProfit = player3totalProfit
            end
        end

        historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
        historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")

        if player3totalProfit >= 0 then
            historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

        player3PPBetText = player3PPBetAmount:GetText()

        if player3PPBetText and player3PPBetText ~= "" then
            player3PPBetAmountValue = tonumber(string.match(player3PPBetText, "%d+"))
            
            if player3PPBetAmountValue then
                if player3PPSideBetWin == false then

                    player3PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName3 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player3totalLoss = player3totalLoss + tonumber(player3PPBetAmountValue)
                            bankingInfo.totalLost = player3totalLoss
                            player3totalProfit = player3totalProfit - tonumber(player3PPBetAmountValue)
                            bankingInfo.totalProfit = player3totalProfit
                        end
                    end
            
                    historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
                    if player3totalProfit >= 0 then
                        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player3213BetText = player3213BetAmount:GetText()

        if player3213BetText and player3213BetText ~= "" then
            player3213BetAmountValue = tonumber(string.match(player3213BetText, "%d+"))

            if player3213BetAmountValue then
                if player3213SideBetWin == false then

                    player3213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName3 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player3totalLoss = player3totalLoss + tonumber(player3213BetAmountValue)
                            bankingInfo.totalLost = player3totalLoss
                            player3totalProfit = player3totalProfit - tonumber(player3213BetAmountValue)
                            bankingInfo.totalProfit = player3totalProfit
                        end
                    end
            
                    historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
                    if player3totalProfit >= 0 then
                        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

function player3Push()
    player3MainBetValue = tonumber(string.match(player3MainBetAmount:GetText(), "%d+"))
    if player3MainBetValue then


        if playerName == unitName3 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3MainBetValue)
                bankingInfo.bankrollTable = player3TotalBankrollAmount
            end
        end

        bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

        player3PPBetText = player3PPBetAmount:GetText()

        if player3PPBetText and player3PPBetText ~= "" then
            player3PPBetAmountValue = tonumber(string.match(player3PPBetText, "%d+"))
            
            if player3PPBetAmountValue then
                if player3PPSideBetWin == false then

                    player3PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName3 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player3totalLoss = player3totalLoss + tonumber(player3PPBetAmountValue)
                            bankingInfo.totalLost = player3totalLoss
                            player3totalProfit = player3totalProfit - tonumber(player3PPBetAmountValue)
                            bankingInfo.totalProfit = player3totalProfit
                        end
                    end
            
                    historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
                    if player3totalProfit >= 0 then
                        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player3213BetText = player3213BetAmount:GetText()

        if player3213BetText and player3213BetText ~= "" then
            player3213BetAmountValue = tonumber(string.match(player3213BetText, "%d+"))

            if player3213BetAmountValue then
                if player3213SideBetWin == false then

                    player3213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName3 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player3totalLoss = player3totalLoss + tonumber(player3213BetAmountValue)
                            bankingInfo.totalLost = player3totalLoss
                            player3totalProfit = player3totalProfit - tonumber(player3213BetAmountValue)
                            bankingInfo.totalProfit = player3totalProfit
                        end
                    end
            
                    historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
                    if player3totalProfit >= 0 then
                        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player3SessionWin = player3SessionWin + tonumber(player3MainBetValue)

    end
end

function player3SplitH1Push()
    player3SplitHand1BetAmountValue = tonumber(string.match(player3SplitH1BetAmount:GetText(), "%d+"))
    if player3SplitHand1BetAmountValue then

        if playerName == unitName3 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3SplitHand1BetAmountValue)
                bankingInfo.bankrollTable = player3TotalBankrollAmount
            end
        end

        bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
   
        player3SessionWin = player3SessionWin + tonumber(player3SplitHand1BetAmountValue)
    
    end
end

function player3SplitH2Push()
    player3SplitHand2BetAmountValue = tonumber(string.match(player3SplitH2BetAmount:GetText(), "%d+"))
    if player3SplitHand2BetAmountValue then

        if playerName == unitName3 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3SplitHand2BetAmountValue)
                bankingInfo.bankrollTable = player3TotalBankrollAmount
            end
        end

        bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

        player3PPBetText = player3PPBetAmount:GetText()

        if player3PPBetText and player3PPBetText ~= "" then
            player3PPBetAmountValue = tonumber(string.match(player3PPBetText, "%d+"))
            
            if player3PPBetAmountValue then
                if player3PPSideBetWin == false then

                    player3PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName3 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player3totalLoss = player3totalLoss + tonumber(player3PPBetAmountValue)
                            bankingInfo.totalLost = player3totalLoss
                            player3totalProfit = player3totalProfit - tonumber(player3PPBetAmountValue)
                            bankingInfo.totalProfit = player3totalProfit
                        end
                    end
            
                    historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
                    if player3totalProfit >= 0 then
                        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player3213BetText = player3213BetAmount:GetText()

        if player3213BetText and player3213BetText ~= "" then
            player3213BetAmountValue = tonumber(string.match(player3213BetText, "%d+"))

            if player3213BetAmountValue then
                if player3213SideBetWin == false then

                    player3213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName3 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player3totalLoss = player3totalLoss + tonumber(player3213BetAmountValue)
                            bankingInfo.totalLost = player3totalLoss
                            player3totalProfit = player3totalProfit - tonumber(player3213BetAmountValue)
                            bankingInfo.totalProfit = player3totalProfit
                        end
                    end
            
                    historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
                    if player3totalProfit >= 0 then
                        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    
        player3SessionWin = player3SessionWin + tonumber(player3SplitHand2BetAmountValue)
    
    end
end

function player3BJWin(message)
    player3MainBetAmountValue = tonumber(string.match(player3MainBetAmount:GetText(), "%d+"))
    if player3MainBetAmountValue then
        player3BJWinAmountValue = player3MainBetAmountValue * 2.5
        player3MainBetAmount:SetText(player3BJWinAmountValue .. " G")
    end

    player3BJProfitvalue = player3BJWinAmountValue - player3MainBetAmountValue

    if playerName == unitName3 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player3totalWin = player3totalWin + tonumber(player3BJProfitvalue)
            bankingInfo.totalWon = player3totalWin
            player3totalProfit = player3totalProfit + tonumber(player3BJProfitvalue)
            bankingInfo.totalProfit = player3totalProfit
            player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3BJWinAmountValue)
            bankingInfo.bankrollTable = player3TotalBankrollAmount
        end
    end

    if player3totalProfit >= 0 then
        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
    bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
    cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

    player3PPBetText = player3PPBetAmount:GetText()

    if player3PPBetText and player3PPBetText ~= "" then
        player3PPBetAmountValue = tonumber(string.match(player3PPBetText, "%d+"))
        
        if player3PPBetAmountValue then
            if player3PPSideBetWin == false then

                player3PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName3 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player3totalLoss = player3totalLoss + tonumber(player3PPBetAmountValue)
                        bankingInfo.totalLost = player3totalLoss
                        player3totalProfit = player3totalProfit - tonumber(player3PPBetAmountValue)
                        bankingInfo.totalProfit = player3totalProfit
                    end
                end
        
                historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
        
                if player3totalProfit >= 0 then
                    historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player3213BetText = player3213BetAmount:GetText()

    if player3213BetText and player3213BetText ~= "" then
        player3213BetAmountValue = tonumber(string.match(player3213BetText, "%d+"))

        if player3213BetAmountValue then
            if player3213SideBetWin == false then

                player3213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName3 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player3totalLoss = player3totalLoss + tonumber(player3213BetAmountValue)
                        bankingInfo.totalLost = player3totalLoss
                        player3totalProfit = player3totalProfit - tonumber(player3213BetAmountValue)
                        bankingInfo.totalProfit = player3totalProfit
                    end
                end
        
                historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
        
                if player3totalProfit >= 0 then
                    historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player3MainBetCoins:Hide()
    playerFrame.player3BJWinCoins:Show()

    player3SessionWin = player3SessionWin + tonumber(player3BJWinAmountValue)

end

function player3SplitH1BJ(message)
    player3SplitHand1BetAmountValue = tonumber(string.match(player3SplitH1BetAmount:GetText(), "%d+"))
    if player3SplitHand1BetAmountValue then
        player3SplitHand1BJWinAmountValue = player3SplitHand1BetAmountValue * 2.5
        player3SplitH1BetAmount:SetText(player3SplitHand1BJWinAmountValue .. " G")
    end

    player3SplitHand1BJProfitValue = player3SplitHand1BJWinAmountValue - player3SplitHand1BetAmountValue

    if playerName == unitName3 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player3totalWin = player3totalWin + tonumber(player3SplitHand1BJProfitValue)
            bankingInfo.totalWon = player3totalWin
            player3totalProfit = player3totalProfit + tonumber(player3SplitHand1BJProfitValue)
            bankingInfo.totalProfit = player3totalProfit
            player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3SplitHand1BJWinAmountValue)
            bankingInfo.bankrollTable = player3TotalBankrollAmount
        end
    end

    if player3totalProfit >= 0 then
        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
    bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
    cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

    playerFrame.player3SplitHand1Coins:Hide()
    playerFrame.player3SplitHand1BJWinCoins:Show()

    player3SessionWin = player3SessionWin + tonumber(player3SplitHand1BJWinAmountValue)

end

function player3SplitH2BJ(message)
    player3SplitHand2BetAmountValue = tonumber(string.match(player3SplitH2BetAmount:GetText(), "%d+"))
    if player3SplitHand2BetAmountValue then
        player3SplitHand2BJWinAmountValue = player3SplitHand2BetAmountValue * 2.5
        player3SplitH2BetAmount:SetText(player3SplitHand2BJWinAmountValue .. " G")
    end

    player3SplitHand2BJProfitValue = player3SplitHand2BJWinAmountValue - player3SplitHand2BetAmountValue

    if playerName == unitName3 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player3totalWin = player3totalWin + tonumber(player3SplitHand2BJProfitValue)
            bankingInfo.totalWon = player3totalWin
            player3totalProfit = player3totalProfit + tonumber(player3SplitHand2BJProfitValue)
            bankingInfo.totalProfit = player3totalProfit
            player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3SplitHand2BJWinAmountValue)
            bankingInfo.bankrollTable = player3TotalBankrollAmount
        end
    end

    if player3totalProfit >= 0 then
        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
    bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
    cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

    player3PPBetText = player3PPBetAmount:GetText()

    if player3PPBetText and player3PPBetText ~= "" then
        player3PPBetAmountValue = tonumber(string.match(player3PPBetText, "%d+"))
        
        if player3PPBetAmountValue then
            if player3PPSideBetWin == false then

                player3PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName3 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player3totalLoss = player3totalLoss + tonumber(player3PPBetAmountValue)
                        bankingInfo.totalLost = player3totalLoss
                        player3totalProfit = player3totalProfit - tonumber(player3PPBetAmountValue)
                        bankingInfo.totalProfit = player3totalProfit
                    end
                end
        
                historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
        
                if player3totalProfit >= 0 then
                    historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player3213BetText = player3213BetAmount:GetText()

    if player3213BetText and player3213BetText ~= "" then
        player3213BetAmountValue = tonumber(string.match(player3213BetText, "%d+"))

        if player3213BetAmountValue then
            if player3213SideBetWin == false then

                player3213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName3 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player3totalLoss = player3totalLoss + tonumber(player3213BetAmountValue)
                        bankingInfo.totalLost = player3totalLoss
                        player3totalProfit = player3totalProfit - tonumber(player3213BetAmountValue)
                        bankingInfo.totalProfit = player3totalProfit
                    end
                end
        
                historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
        
                if player3totalProfit >= 0 then
                    historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player3SplitHand2Coins:Hide()
    playerFrame.player3SplitHand2BJWinCoins:Show()

    player3SessionWin = player3SessionWin + tonumber(player3SplitHand2BJWinAmountValue)

end

function player3Win(message)
    player3MainBetAmountValue = tonumber(string.match(player3MainBetAmount:GetText(), "%d+"))
    if player3MainBetAmountValue then
        player3NormalWinAmountValue = player3MainBetAmountValue * 2
        player3MainBetAmount:SetText(player3NormalWinAmountValue .. " G")

        if playerName == unitName3 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player3totalWin = player3totalWin + tonumber(player3MainBetAmountValue)
                bankingInfo.totalWon = player3totalWin
                player3totalProfit = player3totalProfit + tonumber(player3MainBetAmountValue)
                bankingInfo.totalProfit = player3totalProfit
                player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3NormalWinAmountValue)
                bankingInfo.bankrollTable = player3TotalBankrollAmount
            end
        end
    
        if player3totalProfit >= 0 then
            historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end
    
        historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
        historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
        bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

        player3PPBetText = player3PPBetAmount:GetText()

        if player3PPBetText and player3PPBetText ~= "" then
            player3PPBetAmountValue = tonumber(string.match(player3PPBetText, "%d+"))
            
            if player3PPBetAmountValue then
                if player3PPSideBetWin == false then

                    player3PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName3 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player3totalLoss = player3totalLoss + tonumber(player3PPBetAmountValue)
                            bankingInfo.totalLost = player3totalLoss
                            player3totalProfit = player3totalProfit - tonumber(player3PPBetAmountValue)
                            bankingInfo.totalProfit = player3totalProfit
                        end
                    end
            
                    historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
                    if player3totalProfit >= 0 then
                        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player3213BetText = player3213BetAmount:GetText()

        if player3213BetText and player3213BetText ~= "" then
            player3213BetAmountValue = tonumber(string.match(player3213BetText, "%d+"))

            if player3213BetAmountValue then
                if player3213SideBetWin == false then

                    player3213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName3 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player3totalLoss = player3totalLoss + tonumber(player3213BetAmountValue)
                            bankingInfo.totalLost = player3totalLoss
                            player3totalProfit = player3totalProfit - tonumber(player3213BetAmountValue)
                            bankingInfo.totalProfit = player3totalProfit
                        end
                    end
            
                    historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            
                    if player3totalProfit >= 0 then
                        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end

    playerFrame.player3MainBetCoins:Hide()
    playerFrame.player3NormalWinCoins:Show()

    player3SessionWin = player3SessionWin + tonumber(player3NormalWinAmountValue)

end

function player3SplitH1Win(message)
    player3SplitHand1BetAmountValue = tonumber(string.match(player3SplitH1BetAmount:GetText(), "%d+"))
    if player3SplitHand1BetAmountValue then
        player3SplitHand1NormalWinAmountValue = player3SplitHand1BetAmountValue * 2
        player3SplitH1BetAmount:SetText(player3SplitHand1NormalWinAmountValue .. " G")
    end

    if playerName == unitName3 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player3totalWin = player3totalWin + tonumber(player3SplitHand1BetAmountValue)
            bankingInfo.totalWon = player3totalWin
            player3totalProfit = player3totalProfit + tonumber(player3SplitHand1BetAmountValue)
            bankingInfo.totalProfit = player3totalProfit
            player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3SplitHand1NormalWinAmountValue)
            bankingInfo.bankrollTable = player3TotalBankrollAmount
        end
    end

    if player3totalProfit >= 0 then
        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
    bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
    cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

    playerFrame.player3SplitHand1Coins:Hide()
    playerFrame.player3SplitHand1NormalWinCoins:Show()

    player3SessionWin = player3SessionWin + tonumber(player3SplitHand1NormalWinAmountValue)

end

function player3SplitH2Win(message)
    player3SplitHand2BetAmountValue = tonumber(string.match(player3SplitH2BetAmount:GetText(), "%d+"))
    if player3SplitHand2BetAmountValue then
        player3SplitHand2NormalWinAmountValue = player3SplitHand2BetAmountValue * 2
        player3SplitH2BetAmount:SetText(player3SplitHand2NormalWinAmountValue .. " G")
    end

    if playerName == unitName3 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player3totalWin = player3totalWin + tonumber(player3SplitHand2BetAmountValue)
            bankingInfo.totalWon = player3totalWin
            player3totalProfit = player3totalProfit + tonumber(player3SplitHand2BetAmountValue)
            bankingInfo.totalProfit = player3totalProfit
            player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3SplitHand2NormalWinAmountValue)
            bankingInfo.bankrollTable = player3TotalBankrollAmount
        end
    end

    if player3totalProfit >= 0 then
        historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
    historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
    bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
    cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

    player3PPBetText = player3PPBetAmount:GetText()

    if player3PPBetText and player3PPBetText ~= "" then
        player3PPBetAmountValue = tonumber(string.match(player3PPBetText, "%d+"))
        
        if player3PPBetAmountValue then
            if player3PPSideBetWin == false then

                player3PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName3 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player3totalLoss = player3totalLoss + tonumber(player3PPBetAmountValue)
                        bankingInfo.totalLost = player3totalLoss
                        player3totalProfit = player3totalProfit - tonumber(player3PPBetAmountValue)
                        bankingInfo.totalProfit = player3totalProfit
                    end
                end
        
                historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
        
                if player3totalProfit >= 0 then
                    historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player3213BetText = player3213BetAmount:GetText()

    if player3213BetText and player3213BetText ~= "" then
        player3213BetAmountValue = tonumber(string.match(player3213BetText, "%d+"))

        if player3213BetAmountValue then
            if player3213SideBetWin == false then

                player3213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName3 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player3totalLoss = player3totalLoss + tonumber(player3213BetAmountValue)
                        bankingInfo.totalLost = player3totalLoss
                        player3totalProfit = player3totalProfit - tonumber(player3213BetAmountValue)
                        bankingInfo.totalProfit = player3totalProfit
                    end
                end
        
                historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
                historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
        
                if player3totalProfit >= 0 then
                    historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player3SplitHand2Coins:Hide()
    playerFrame.player3SplitHand2NormalWinCoins:Show()

    player3SessionWin = player3SessionWin + tonumber(player3SplitHand2NormalWinAmountValue)

end

function player3InsuranceWin(message)

    player3InsuranceBetText = playerFrame.player3InsuranceBetAmount:GetText()

    if player3InsuranceBetText and player3InsuranceBetText ~= "" then
        player3InsuranceBetAmountValue = tonumber(string.match(player3InsuranceBetText, "%d+"))

        if player3InsuranceBetAmountValue then
            player3InsuranceWinAmountValue = player3InsuranceBetAmountValue * 3

            player3InsuranceProfitValue = player3InsuranceWinAmountValue - player3InsuranceBetAmountValue


            if playerName == unitName3 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player3totalWin = player3totalWin + tonumber(player3InsuranceProfitValue)
                    bankingInfo.totalWon = player3totalWin
                    player3totalProfit = player3totalProfit + tonumber(player3InsuranceProfitValue)
                    bankingInfo.totalProfit = player3totalProfit
                    player3TotalBankrollAmount = player3TotalBankrollAmount + tonumber(player3InsuranceWinAmountValue)
                    bankingInfo.bankrollTable = player3TotalBankrollAmount
                end
            end
        
            if player3totalProfit >= 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
        
            historyFrame.player3totalWonAmount:SetText(player3totalWin .. " G")
            historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")
            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")

            player3SessionWin = player3SessionWin + tonumber(player3InsuranceWinAmountValue)

        end
    end
end

function player3InsuranceLoss(message)

    player3InsuranceBetText = playerFrame.player3InsuranceBetAmount:GetText()

    if player3InsuranceBetText and player3InsuranceBetText ~= "" then
        player3InsuranceBetAmountValue = tonumber(string.match(player3InsuranceBetText, "%d+"))

        if player3InsuranceBetAmountValue then

            if playerName == unitName3 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player3totalLoss = player3totalLoss + tonumber(player3InsuranceBetAmountValue)
                    bankingInfo.totalLost = player3totalLoss
                    player3totalProfit = player3totalProfit - tonumber(player3InsuranceBetAmountValue)
                    bankingInfo.totalProfit = player3totalProfit
                end
            end
    
            if player3totalProfit >= 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
    
            historyFrame.player3totalLostAmount:SetText(player3totalLoss .. " G")
            historyFrame.player3ProfitAmount:SetText(player3totalProfit .. " G")

        end
    end
end

function player3SessionWinAnnouncement()
    if playerName == unitName3 then
        if player3SessionWinCalled == false then
            if player3SessionWin >= 50 then
                chatFrame = SELECTED_DOCK_FRAME
                ChatFrame_OpenChat("/me", chatFrame)
                
                editBox = _G[chatFrame:GetName().."EditBox"]
                editBox:SetText("")
                editBox:Insert("/me has won " .. player3SessionWin .. "g from a hand of Blackjack.")
                
                ChatEdit_SendText(editBox)
                ChatEdit_DeactivateChat(editBox)

                UpdateWinningsDisplay(playerFrame.player3WinningsUpdate, player3SessionWin)
                player3resetRaidChannel()
                
            else
                print("")
            end

            player3SessionWinCalled = true
        end
    end
end


















-- >>> PLAYER 4 <<<
-- >>> PLAYER 4 <<<
-- >>> PLAYER 4 <<<

playerFrame.player4CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", -210, 230)
playerFrame.player4CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 28, "OUTLINE") -- Adjust the font and size as needed
playerFrame.player4CardTotalText:SetText("")

playerFrame.player4SplitHand1CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4SplitHand1CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", -180, 224)
playerFrame.player4SplitHand1CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
playerFrame.player4SplitHand1CardTotalText:SetText("")

playerFrame.player4SplitHand2CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4SplitHand2CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", -240, 247)
playerFrame.player4SplitHand2CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
playerFrame.player4SplitHand2CardTotalText:SetText("")

-- Buttons for Player 4
-- Hit
playerFrame.player4HitButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4HitButton:SetPoint("BOTTOM", playerFrame, -288, 135)
playerFrame.player4HitButton:SetSize(65, 30)
playerFrame.player4HitButton:SetText("Hit")
playerFrame.player4HitButton:Disable()
playerFrame.player4HitButton:Hide()
-- Stand
playerFrame.player4StandButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4StandButton:SetPoint("BOTTOM", playerFrame, -222, 135)
playerFrame.player4StandButton:SetSize(65, 30)
playerFrame.player4StandButton:SetText("Stand")
playerFrame.player4StandButton:Disable()
playerFrame.player4StandButton:Hide()
-- Double
playerFrame.player4DoubleButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4DoubleButton:SetPoint("BOTTOM", playerFrame, -288, 105)
playerFrame.player4DoubleButton:SetSize(65, 30)
playerFrame.player4DoubleButton:SetText("Double")
playerFrame.player4DoubleButton:Disable()
playerFrame.player4DoubleButton:Hide()
-- Split
playerFrame.player4SplitButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4SplitButton:SetPoint("BOTTOM", playerFrame, -222, 105)
playerFrame.player4SplitButton:SetSize(65, 30)
playerFrame.player4SplitButton:SetText("Split")
playerFrame.player4SplitButton:Disable()
playerFrame.player4SplitButton:Hide()
-- Insurance Yes
playerFrame.player4InsuranceYesButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4InsuranceYesButton:SetPoint("BOTTOM", playerFrame, -320, 75)
playerFrame.player4InsuranceYesButton:SetSize(55, 30)
playerFrame.player4InsuranceYesButton:SetText("Yes")
playerFrame.player4InsuranceYesButton:Disable()
playerFrame.player4InsuranceYesButton:Hide()
-- Insurance No
playerFrame.player4InsuranceNoButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4InsuranceNoButton:SetPoint("BOTTOM", playerFrame, -195, 75)
playerFrame.player4InsuranceNoButton:SetSize(55, 30)
playerFrame.player4InsuranceNoButton:SetText("No")
playerFrame.player4InsuranceNoButton:Disable()
playerFrame.player4InsuranceNoButton:Hide()
-- Deal Now
playerFrame.player4DealNowButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4DealNowButton:SetPoint("BOTTOM", playerFrame, -255, 75)
playerFrame.player4DealNowButton:SetSize(85, 30)
playerFrame.player4DealNowButton:SetText("Deal Now")
playerFrame.player4DealNowButton:Disable()
playerFrame.player4DealNowButton:Hide()
-- Hit (Split H1)
playerFrame.player4HitButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4HitButtonSplitH1:SetPoint("BOTTOM", playerFrame, -225, 135)
playerFrame.player4HitButtonSplitH1:SetSize(65, 30)
playerFrame.player4HitButtonSplitH1:SetText("Hit")
playerFrame.player4HitButtonSplitH1:Disable()
playerFrame.player4HitButtonSplitH1:Hide()
-- Stand (Split H1)
playerFrame.player4StandButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4StandButtonSplitH1:SetPoint("BOTTOM", playerFrame, -225, 105)
playerFrame.player4StandButtonSplitH1:SetSize(65, 30)
playerFrame.player4StandButtonSplitH1:SetText("Stand")
playerFrame.player4StandButtonSplitH1:Disable()
playerFrame.player4StandButtonSplitH1:Hide()
-- Double (Split H1)
playerFrame.player4DoubleButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4DoubleButtonSplitH1:SetPoint("BOTTOM", playerFrame, -225, 75)
playerFrame.player4DoubleButtonSplitH1:SetSize(65, 30)
playerFrame.player4DoubleButtonSplitH1:SetText("Double")
playerFrame.player4DoubleButtonSplitH1:Disable()
playerFrame.player4DoubleButtonSplitH1:Hide()
-- Hit (Split H2)
playerFrame.player4HitButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4HitButtonSplitH2:SetPoint("BOTTOM", playerFrame, -291, 135)
playerFrame.player4HitButtonSplitH2:SetSize(65, 30)
playerFrame.player4HitButtonSplitH2:SetText("Hit")
playerFrame.player4HitButtonSplitH2:Disable()
playerFrame.player4HitButtonSplitH2:Hide()
-- Stand (Split H2)
playerFrame.player4StandButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4StandButtonSplitH2:SetPoint("BOTTOM", playerFrame, -291, 105)
playerFrame.player4StandButtonSplitH2:SetSize(65, 30)
playerFrame.player4StandButtonSplitH2:SetText("Stand")
playerFrame.player4StandButtonSplitH2:Disable()
playerFrame.player4StandButtonSplitH2:Hide()
-- Double (Split H2)
playerFrame.player4DoubleButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player4DoubleButtonSplitH2:SetPoint("BOTTOM", playerFrame, -291, 75)
playerFrame.player4DoubleButtonSplitH2:SetSize(65, 30)
playerFrame.player4DoubleButtonSplitH2:SetText("Double")
playerFrame.player4DoubleButtonSplitH2:Disable()
playerFrame.player4DoubleButtonSplitH2:Hide()
-- Main Bet Confirm
player4ConfirmMainBetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player4ConfirmMainBetButton:SetPoint("BOTTOM", playerFrame, -222, 195)
player4ConfirmMainBetButton:SetSize(65, 30)
player4ConfirmMainBetButton:SetText("Bet")
player4ConfirmMainBetButton:Hide()
-- Perfect Pairs Confirm
player4ConfirmPPBetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player4ConfirmPPBetButton:SetPoint("BOTTOM", playerFrame, -237, 295)
player4ConfirmPPBetButton:SetSize(43, 25)
player4ConfirmPPBetButton:SetText("Bet")
player4ConfirmPPBetButton:Hide()
-- 21+3 Confirm
player4Confirm213BetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player4Confirm213BetButton:SetPoint("BOTTOM", playerFrame, -121, 244)
player4Confirm213BetButton:SetSize(43, 25)
player4Confirm213BetButton:SetText("Bet")
player4Confirm213BetButton:Hide()

-- Wagers for Player 4
-- Main Bet
player4MainBetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player4MainBetEditBox:SetSize(55, 30)
player4MainBetEditBox:SetPoint("BOTTOM", playerFrame, -284, 195)
player4MainBetEditBox:SetAutoFocus(false)
player4MainBetEditBox:SetNumeric(true)
player4MainBetEditBox:Hide()
-- Split Hand 1
player4SplitH1EditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player4SplitH1EditBox:SetSize(55, 30)
player4SplitH1EditBox:SetPoint("BOTTOM", playerFrame, -219, 195)
player4SplitH1EditBox:SetAutoFocus(false)
player4SplitH1EditBox:SetNumeric(true)
player4SplitH1EditBox:ClearFocus()
player4SplitH1EditBox:Disable()
player4SplitH1EditBox:Hide()
-- Split Hand 2
player4SplitH2EditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player4SplitH2EditBox:SetSize(55, 30)
player4SplitH2EditBox:SetPoint("BOTTOM", playerFrame, -284, 195)
player4SplitH2EditBox:SetAutoFocus(false)
player4SplitH2EditBox:SetNumeric(true)
player4SplitH2EditBox:ClearFocus()
player4SplitH2EditBox:Disable()
player4SplitH2EditBox:Hide()
-- Perfect Pairs
player4PPBetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player4PPBetEditBox:SetSize(35, 30)
player4PPBetEditBox:SetPoint("BOTTOM", playerFrame, -235, 315)
player4PPBetEditBox:SetAutoFocus(false)
player4PPBetEditBox:SetNumeric(true)
player4PPBetEditBox:Hide()
-- 21+3
player4213BetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player4213BetEditBox:SetSize(35, 30)
player4213BetEditBox:SetPoint("BOTTOM", playerFrame, -119, 264)
player4213BetEditBox:SetAutoFocus(false)
player4213BetEditBox:SetNumeric(true)
player4213BetEditBox:Hide()

-- Labels for Player 4
-- Main Bet
playerFrame.player4MainBetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4MainBetTitle:SetPoint("BOTTOM", playerFrame, -284, 222)
playerFrame.player4MainBetTitle:SetJustifyH("CENTER")
playerFrame.player4MainBetTitle:SetText("Main Bet")
playerFrame.player4MainBetTitle:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player4MainBetTitle:Hide()
-- Split Hand 1
playerFrame.player4SplitH1Title = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4SplitH1Title:SetPoint("BOTTOM", playerFrame, -219, 222)
playerFrame.player4SplitH1Title:SetJustifyH("CENTER")
playerFrame.player4SplitH1Title:SetText("Hand 1")
playerFrame.player4SplitH1Title:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player4SplitH1Title:Hide()
-- Split Hand 2
playerFrame.player4SplitH2Title = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4SplitH2Title:SetPoint("BOTTOM", playerFrame, -284, 222)
playerFrame.player4SplitH2Title:SetJustifyH("CENTER")
playerFrame.player4SplitH2Title:SetText("Hand 2")
playerFrame.player4SplitH2Title:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player4SplitH2Title:Hide()
-- Main Bet Amount
player4MainBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4MainBetAmount:SetPoint("CENTER", playerFrame, -179, -18)
player4MainBetAmount:SetJustifyH("CENTER")
player4MainBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Split Hand 1 Amount
player4SplitH1BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4SplitH1BetAmount:SetPoint("CENTER", playerFrame, -158, -23)
player4SplitH1BetAmount:SetJustifyH("CENTER")
player4SplitH1BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Split Hand 2 Amount
player4SplitH2BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4SplitH2BetAmount:SetPoint("CENTER", playerFrame, -191, -8)
player4SplitH2BetAmount:SetJustifyH("CENTER")
player4SplitH2BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Perfect Pairs
playerFrame.player4PPBetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4PPBetTitle:SetPoint("BOTTOM", playerFrame, -270, 312)
playerFrame.player4PPBetTitle:SetJustifyH("CENTER")
playerFrame.player4PPBetTitle:SetText("PP")
playerFrame.player4PPBetTitle:SetFont("Fonts\\FRIZQT__.TTF", 15, "OUTLINE")
playerFrame.player4PPBetTitle:Hide()
-- Perfect Pairs Amount
player4PPBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4PPBetAmount:SetPoint("CENTER", playerFrame, -219, 26)
player4PPBetAmount:SetJustifyH("CENTER")
player4PPBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- 21+3
playerFrame.player4213BetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4213BetTitle:SetPoint("BOTTOM", playerFrame, -75, 259)
playerFrame.player4213BetTitle:SetJustifyH("CENTER")
playerFrame.player4213BetTitle:SetText("21+3")
playerFrame.player4213BetTitle:SetFont("Fonts\\FRIZQT__.TTF", 15, "OUTLINE")
playerFrame.player4213BetTitle:Hide()
-- 21+3 Amount
player4213BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4213BetAmount:SetPoint("CENTER", playerFrame, -107, -25)
player4213BetAmount:SetJustifyH("CENTER")
player4213BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Insurance Amount
playerFrame.player4InsuranceBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4InsuranceBetAmount:SetPoint("CENTER", playerFrame, -149, -250)
playerFrame.player4InsuranceBetAmount:SetJustifyH("CENTER")
playerFrame.player4InsuranceBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
-- Player Name
playerFrame.player4Name = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4Name:SetPoint("BOTTOM", playerFrame, -255, 171)
playerFrame.player4Name:SetText("Seat Empty")
playerFrame.player4Name:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
-- Insurance
playerFrame.player4InsuranceTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4InsuranceTitle:SetPoint("BOTTOM", playerFrame, -255, 89)
playerFrame.player4InsuranceTitle:SetText("Insurance")
playerFrame.player4InsuranceTitle:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
playerFrame.player4InsuranceTitle:Hide()
-- Insurance (if available)
playerFrame.player4InsuranceSubtitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4InsuranceSubtitle:SetPoint("BOTTOM", playerFrame, -255, 79)
playerFrame.player4InsuranceSubtitle:SetText("(if available)")
playerFrame.player4InsuranceSubtitle:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player4InsuranceSubtitle:Hide()
-- Session Win Update
playerFrame.player4WinningsUpdate = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player4WinningsUpdate:SetPoint("BOTTOMLEFT", playerFrame, 270, 30) 
playerFrame.player4WinningsUpdate:SetText("")
playerFrame.player4WinningsUpdate:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
playerFrame.player4WinningsUpdate:SetTextColor(0.118, 0.839, 0.412)

-- Images for Player 4
-- Turn Arrow
playerFrame.player4TurnArrow = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4TurnArrow:SetSize(128, 128)
playerFrame.player4TurnArrow:SetPoint("CENTER", playerFrame, -146, -158)
playerFrame.player4TurnArrow:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\TurnArrow.tga")
playerFrame.player4TurnArrow:SetBlendMode("BLEND")
playerFrame.player4TurnArrow:SetDrawLayer("OVERLAY")
playerFrame.player4TurnArrow:Hide()
-- Main Bet
playerFrame.player4MainBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4MainBetCoins:SetSize(128, 128)
playerFrame.player4MainBetCoins:SetPoint("CENTER", playerFrame, -163, -48)
playerFrame.player4MainBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player4MainBetCoins:SetBlendMode("BLEND")
playerFrame.player4MainBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player4MainBetCoins:Hide()
-- Win
playerFrame.player4NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4NormalWinCoins:SetSize(128, 128)
playerFrame.player4NormalWinCoins:SetPoint("CENTER", playerFrame, -163, -48)
playerFrame.player4NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player4NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player4NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player4NormalWinCoins:Hide()
-- Split Hand 2 Bet
playerFrame.player4SplitHand2Coins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4SplitHand2Coins:SetSize(128, 128)
playerFrame.player4SplitHand2Coins:SetPoint("CENTER", playerFrame, -175, -40)
playerFrame.player4SplitHand2Coins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player4SplitHand2Coins:SetBlendMode("BLEND")
playerFrame.player4SplitHand2Coins:SetDrawLayer("OVERLAY")
playerFrame.player4SplitHand2Coins:Hide()
-- Split Double Hand 2 Bet
playerFrame.player4SplitHand2DoubleCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4SplitHand2DoubleCoins:SetSize(128, 128)
playerFrame.player4SplitHand2DoubleCoins:SetPoint("CENTER", playerFrame, -175, -40)
playerFrame.player4SplitHand2DoubleCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player4SplitHand2DoubleCoins:SetBlendMode("BLEND")
playerFrame.player4SplitHand2DoubleCoins:SetDrawLayer("OVERLAY")
playerFrame.player4SplitHand2DoubleCoins:Hide()
-- Split Win Hand 2
playerFrame.player4SplitHand2NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4SplitHand2NormalWinCoins:SetSize(128, 128)
playerFrame.player4SplitHand2NormalWinCoins:SetPoint("CENTER", playerFrame, -175, -40)
playerFrame.player4SplitHand2NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player4SplitHand2NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player4SplitHand2NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player4SplitHand2NormalWinCoins:Hide()
-- Split Hand 1 Bet
playerFrame.player4SplitHand1Coins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4SplitHand1Coins:SetSize(128, 128)
playerFrame.player4SplitHand1Coins:SetPoint("CENTER", playerFrame, -143, -55)
playerFrame.player4SplitHand1Coins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player4SplitHand1Coins:SetBlendMode("BLEND")
playerFrame.player4SplitHand1Coins:SetDrawLayer("OVERLAY")
playerFrame.player4SplitHand1Coins:Hide()
-- Split Double Hand 1 Bet
playerFrame.player4SplitHand1DoubleCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4SplitHand1DoubleCoins:SetSize(128, 128)
playerFrame.player4SplitHand1DoubleCoins:SetPoint("CENTER", playerFrame, -143, -55)
playerFrame.player4SplitHand1DoubleCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player4SplitHand1DoubleCoins:SetBlendMode("BLEND")
playerFrame.player4SplitHand1DoubleCoins:SetDrawLayer("OVERLAY")
playerFrame.player4SplitHand1DoubleCoins:Hide()
-- Split Win Hand 1
playerFrame.player4SplitHand1NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4SplitHand1NormalWinCoins:SetSize(128, 128)
playerFrame.player4SplitHand1NormalWinCoins:SetPoint("CENTER", playerFrame, -143, -55)
playerFrame.player4SplitHand1NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player4SplitHand1NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player4SplitHand1NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player4SplitHand1NormalWinCoins:Hide()
-- Blackjack Win
playerFrame.player4BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4BJWinCoins:SetSize(128, 128)
playerFrame.player4BJWinCoins:SetPoint("CENTER", playerFrame, -163, -48)
playerFrame.player4BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player4BJWinCoins:SetBlendMode("BLEND")
playerFrame.player4BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player4BJWinCoins:Hide()
-- Split BJ Win Hand 2
playerFrame.player4SplitHand2BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4SplitHand2BJWinCoins:SetSize(128, 128)
playerFrame.player4SplitHand2BJWinCoins:SetPoint("CENTER", playerFrame, -175, -40)
playerFrame.player4SplitHand2BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player4SplitHand2BJWinCoins:SetBlendMode("BLEND")
playerFrame.player4SplitHand2BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player4SplitHand2BJWinCoins:Hide()
-- Split BJ Win Hand 1
playerFrame.player4SplitHand1BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4SplitHand1BJWinCoins:SetSize(128, 128)
playerFrame.player4SplitHand1BJWinCoins:SetPoint("CENTER", playerFrame, -143, -55)
playerFrame.player4SplitHand1BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player4SplitHand1BJWinCoins:SetBlendMode("BLEND")
playerFrame.player4SplitHand1BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player4SplitHand1BJWinCoins:Hide()
-- Double Bet
playerFrame.player4DoubleBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4DoubleBetCoins:SetSize(128, 128)
playerFrame.player4DoubleBetCoins:SetPoint("CENTER", playerFrame, -163, -48)
playerFrame.player4DoubleBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player4DoubleBetCoins:SetBlendMode("BLEND")
playerFrame.player4DoubleBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player4DoubleBetCoins:Hide()
-- PP Bet
playerFrame.player4PPBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4PPBetCoins:SetSize(128, 128)
playerFrame.player4PPBetCoins:SetPoint("CENTER", playerFrame, -215, 8)
playerFrame.player4PPBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsHalfBet.tga")
playerFrame.player4PPBetCoins:SetBlendMode("BLEND")
playerFrame.player4PPBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player4PPBetCoins:Hide()
-- 21+3 Bet
playerFrame.player4213BetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4213BetCoins:SetSize(128, 128)
playerFrame.player4213BetCoins:SetPoint("CENTER", playerFrame, -102, -44)
playerFrame.player4213BetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsHalfBet.tga")
playerFrame.player4213BetCoins:SetBlendMode("BLEND")
playerFrame.player4213BetCoins:SetDrawLayer("OVERLAY")
playerFrame.player4213BetCoins:Hide()
-- PP Win
playerFrame.player4PPWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4PPWinCoins:SetSize(128, 128)
playerFrame.player4PPWinCoins:SetPoint("CENTER", playerFrame, -203, 14)
playerFrame.player4PPWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player4PPWinCoins:SetBlendMode("BLEND")
playerFrame.player4PPWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player4PPWinCoins:Hide()
-- 21+3 Win
playerFrame.player4213WinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player4213WinCoins:SetSize(128, 128)
playerFrame.player4213WinCoins:SetPoint("CENTER", playerFrame, -92, -38)
playerFrame.player4213WinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player4213WinCoins:SetBlendMode("BLEND")
playerFrame.player4213WinCoins:SetDrawLayer("OVERLAY")
playerFrame.player4213WinCoins:Hide()
-- Insurance YES for Player 4
player4InsuranceYesIcon = playerFrame:CreateTexture(nil, "OVERLAY")
player4InsuranceYesIcon:SetSize(24, 24)
player4InsuranceYesIcon:SetPoint("CENTER", playerFrame, -152, -270)
player4InsuranceYesIcon:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\insuranceYes.tga")
player4InsuranceYesIcon:SetDrawLayer("OVERLAY")
player4InsuranceYesIcon:Hide()
-- Insurance NO for Player 4
player4InsuranceNoIcon = playerFrame:CreateTexture(nil, "OVERLAY")
player4InsuranceNoIcon:SetSize(24, 24)
player4InsuranceNoIcon:SetPoint("CENTER", playerFrame, -152, -270)
player4InsuranceNoIcon:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\insuranceNo.tga")
player4InsuranceNoIcon:SetDrawLayer("OVERLAY")
player4InsuranceNoIcon:Hide()

-- BJ Win Coins
function player4PlaceCoinsBJWin(message)
    playerFrame.player4MainBetCoins:Hide()
    playerFrame.player4BJWinCoins:Show()
end

-- Regular Win Coins
function player4PlaceCoinsRegularWin(message)
    playerFrame.player4MainBetCoins:Hide()
    playerFrame.player4DoubleBetCoins:Show()
end

-- Main Bet Coins
function player4PlaceCoinsMainBet(message)
    playerFrame.player4MainBetCoins:Show()
end

-- Double Bet Coins
function player4PlaceCoinsDoubleBet(message)
    playerFrame.player4MainBetCoins:Hide()
    playerFrame.player4DoubleBetCoins:Show()
end

-- Function to handle Player 4 Main Bet Text
function player4PlaceTextMainBet(message)
    player4HistoryMainBet = string.match(message, "(%d+)G")

        if player4HistoryMainBet then
            player4MainBetAmount:SetText(player4HistoryMainBet .. " G")
            player4MainBetAmount:Show()

            if playerName == unitName4 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName4]
                    player4totalBetAmount = player4totalBetAmount + tonumber(player4HistoryMainBet)
                    bankingInfo.totalWagered = player4totalBetAmount
                end
            end

            historyFrame.player4totalWageredAmount:SetText(player4totalBetAmount .. " G")

        else
    end
end

-- Player 4 Split Hand Bet Text
function player4SplitHand1BetText(Amount)
    player4MainBetAmount:Hide()
    player4MainBetAmount:SetText("")
    player4SplitH1BetAmount:SetText(Amount .. " G")
    player4SplitH1BetAmount:Show()
    player4SplitH2BetAmount:SetText(Amount .. " G")
    player4SplitH2BetAmount:Show()
end

-- Player 4 Split Bet Image
function player4PlaceSplitBet(message)
    playerFrame.player4MainBetCoins:Hide()
    playerFrame.player4SplitHand1Coins:Show()
    playerFrame.player4SplitHand2Coins:Show()
end

-- Player 4 Place Initial Card Images
function player4PlaceSplitCards(message)

    -- Players: 4
    if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
        drawnCards[1]:Hide()
        drawnCards[3]:Hide()
        player4cardName1 = dealtCards[1]
        player4cardName2 = dealtCards[3]
        turn = 8 -- Player 4: 2nd Card (Split H1)

    -- Players: 1, 4
    elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
        drawnCards[2]:Hide()
        drawnCards[5]:Hide()
        player4cardName1 = dealtCards[2]
        player4cardName2 = dealtCards[5]
        turn = 30 -- Player 4: 2nd Card (Split H1)
    -- Players: 2, 4
    elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
        drawnCards[2]:Hide()
        drawnCards[5]:Hide()
        player4cardName1 = dealtCards[2]
        player4cardName2 = dealtCards[5]
        turn = 30 -- Player 4: 2nd Card (Split H1)
    -- Players: 3, 4
    elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
        drawnCards[2]:Hide()
        drawnCards[5]:Hide()
        player4cardName1 = dealtCards[2]
        player4cardName2 = dealtCards[5]
        turn = 30 -- Player 4: 2nd Card (Split H1)
    -- Players: 4, 5
    elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
        drawnCards[1]:Hide()
        drawnCards[4]:Hide()
        player4cardName1 = dealtCards[1]
        player4cardName2 = dealtCards[4]
        turn = 10 -- Player 4: 2nd Card (Split H1)

    -- Players: 1, 2, 4
    elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
        drawnCards[3]:Hide()
        drawnCards[7]:Hide()
        player4cardName1 = dealtCards[3]
        player4cardName2 = dealtCards[7]
        turn = 52 -- Player 4: 2nd Card (Split H1)
    -- Players: 1, 3, 4
    elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
        drawnCards[3]:Hide()
        drawnCards[7]:Hide()
        player4cardName1 = dealtCards[3]
        player4cardName2 = dealtCards[7]
        turn = 52 -- Player 4: 2nd Card (Split H1)
    -- Players: 1, 4, 5
    elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
        drawnCards[2]:Hide()
        drawnCards[6]:Hide()
        player4cardName1 = dealtCards[2]
        player4cardName2 = dealtCards[6]
        turn = 32 -- Player 4: 2nd Card (Split H1)
    -- Players: 2, 3, 4
    elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
        drawnCards[3]:Hide()
        drawnCards[7]:Hide()
        player4cardName1 = dealtCards[3]
        player4cardName2 = dealtCards[7]
        turn = 52 -- Player 4: 2nd Card (Split H1)
    -- Players: 2, 4, 5
    elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
        drawnCards[2]:Hide()
        drawnCards[6]:Hide()
        player4cardName1 = dealtCards[2]
        player4cardName2 = dealtCards[6]
        turn = 32 -- Player 4: 2nd Card (Split H1)
    -- Players: 3, 4, 5
    elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
        drawnCards[2]:Hide()
        drawnCards[6]:Hide()
        player4cardName1 = dealtCards[2]
        player4cardName2 = dealtCards[6]
        turn = 32 -- Player 4: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4
    elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
        drawnCards[4]:Hide()
        drawnCards[9]:Hide()
        player4cardName1 = dealtCards[4]
        player4cardName2 = dealtCards[9]
        turn = 74 -- Player 4: 2nd Card (Split H1)
    -- Players: 1, 2, 4, 5
    elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
        drawnCards[3]:Hide()
        drawnCards[8]:Hide()
        player4cardName1 = dealtCards[3]
        player4cardName2 = dealtCards[8]
        turn = 54 -- Player 4: 2nd Card (Split H1)
    -- Players: 1, 3, 4, 5
    elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
        drawnCards[3]:Hide()
        drawnCards[8]:Hide()
        player4cardName1 = dealtCards[3]
        player4cardName2 = dealtCards[8]
        turn = 54 -- Player 4: 2nd Card (Split H1)
    -- Players: 2, 3, 4, 5
    elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
        drawnCards[3]:Hide()
        drawnCards[8]:Hide()
        player4cardName1 = dealtCards[3]
        player4cardName2 = dealtCards[8]
        turn = 54 -- Player 4: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4, 5
    elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
        drawnCards[4]:Hide()
        drawnCards[10]:Hide()
        player4cardName1 = dealtCards[4]
        player4cardName2 = dealtCards[10]
        turn = 76 -- Player 4: 2nd Card (Split H1)
    end

    player4cardImageFile1 = nil
    player4cardImageFile2 = nil

    for filename, cardDescription in pairs(cardNames) do
        if cardDescription == player4cardName1 then
            player4cardImageFile1 = filename
            break
        end
    end

    for filename, cardDescription in pairs(cardNames) do
        if cardDescription == player4cardName2 then
            player4cardImageFile2 = filename
            break
        end
    end

    player4NewCardImage1 = CreateFrame("Frame", nil, playerFrame)
    player4NewCardImage1:SetSize(32, 64)
    player4NewCardImage1:SetPoint("BOTTOM", playerFrame, -142, 325)
    player4NewCardImage1.texture = player4NewCardImage1:CreateTexture()
    player4NewCardImage1.texture:SetAllPoints()
    player4NewCardImage1.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4cardImageFile1)
    player4NewCardImage1:Show()

    player4NewCardImage2 = CreateFrame("Frame", nil, playerFrame)
    player4NewCardImage2:SetSize(32, 64)
    player4NewCardImage2:SetPoint("BOTTOM", playerFrame, -182, 345)
    player4NewCardImage2.texture = player4NewCardImage2:CreateTexture()
    player4NewCardImage2.texture:SetAllPoints()
    player4NewCardImage2.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4cardImageFile2)
    player4NewCardImage2:Show()

end

-- Player 4 Split Function
function player4HandleSplit(message)
    player4PlaceSplitBet()
    player4MainBetAmountValue = tonumber(string.match(player4MainBetAmount:GetText(), "%d+"))
    if player4MainBetAmountValue then
        player4SplitHand1BetText(player4MainBetAmountValue)
    end 

    player4PlaceSplitCards()

    -- A,A
    if playerFrame.player4CardTotalText:GetText() == "2 or 12" then
        playerFrame.player4SplitHand1CardTotalText:SetText("1 or 11")
        playerFrame.player4SplitHand1CardTotalText:Show()
        playerFrame.player4SplitHand2CardTotalText:SetText("1 or 11")
        playerFrame.player4SplitHand2CardTotalText:Show()
    -- 2,2
    elseif playerFrame.player4CardTotalText:GetText() == "4" then
        playerFrame.player4SplitHand1CardTotalText:SetText("2")
        playerFrame.player4SplitHand1CardTotalText:Show()
        playerFrame.player4SplitHand2CardTotalText:SetText("2")
        playerFrame.player4SplitHand2CardTotalText:Show()
    -- 3,3
    elseif playerFrame.player4CardTotalText:GetText() == "6" then
        playerFrame.player4SplitHand1CardTotalText:SetText("3")
        playerFrame.player4SplitHand1CardTotalText:Show()
        playerFrame.player4SplitHand2CardTotalText:SetText("3")
        playerFrame.player4SplitHand2CardTotalText:Show()
    -- 4,4
    elseif playerFrame.player4CardTotalText:GetText() == "8" then
        playerFrame.player4SplitHand1CardTotalText:SetText("4")
        playerFrame.player4SplitHand1CardTotalText:Show()
        playerFrame.player4SplitHand2CardTotalText:SetText("4")
        playerFrame.player4SplitHand2CardTotalText:Show()
    -- 5,5
    elseif playerFrame.player4CardTotalText:GetText() == "10" then
        playerFrame.player4SplitHand1CardTotalText:SetText("5")
        playerFrame.player4SplitHand1CardTotalText:Show()
        playerFrame.player4SplitHand2CardTotalText:SetText("5")
        playerFrame.player4SplitHand2CardTotalText:Show()
    -- 6,6
    elseif playerFrame.player4CardTotalText:GetText() == "12" then
        playerFrame.player4SplitHand1CardTotalText:SetText("6")
        playerFrame.player4SplitHand1CardTotalText:Show()
        playerFrame.player4SplitHand2CardTotalText:SetText("6")
        playerFrame.player4SplitHand2CardTotalText:Show()
    -- 7,7
    elseif playerFrame.player4CardTotalText:GetText() == "14" then
        playerFrame.player4SplitHand1CardTotalText:SetText("7")
        playerFrame.player4SplitHand1CardTotalText:Show()
        playerFrame.player4SplitHand2CardTotalText:SetText("7")
        playerFrame.player4SplitHand2CardTotalText:Show()
    -- 8,8
    elseif playerFrame.player4CardTotalText:GetText() == "16" then
        playerFrame.player4SplitHand1CardTotalText:SetText("8")
        playerFrame.player4SplitHand1CardTotalText:Show()
        playerFrame.player4SplitHand2CardTotalText:SetText("8")
        playerFrame.player4SplitHand2CardTotalText:Show()
    -- 9,9
    elseif playerFrame.player4CardTotalText:GetText() == "18" then
        playerFrame.player4SplitHand1CardTotalText:SetText("9")
        playerFrame.player4SplitHand1CardTotalText:Show()
        playerFrame.player4SplitHand2CardTotalText:SetText("9")
        playerFrame.player4SplitHand2CardTotalText:Show()
    -- 10,10
    elseif playerFrame.player4CardTotalText:GetText() == "20" then
        playerFrame.player4SplitHand1CardTotalText:SetText("10")
        playerFrame.player4SplitHand1CardTotalText:Show()
        playerFrame.player4SplitHand2CardTotalText:SetText("10")
        playerFrame.player4SplitHand2CardTotalText:Show()
    end

    playerFrame.player4CardTotalText:SetText("")
    playerFrame.player4CardTotalText:Hide()
    
    if playerName == unitName4 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player4totalBetAmount = player4totalBetAmount + tonumber(player4MainBetAmountValue)
            bankingInfo.totalWagered = player4totalBetAmount
            player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(player4MainBetAmountValue)
            bankingInfo.bankrollTable = player4TotalBankrollAmount
        end
    end

    historyFrame.player4totalWageredAmount:SetText(player4totalBetAmount .. " G")
    bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
    cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

    player4SplitToggle = true

    if player4dealtCardsFrame:IsShown() then
        player4dealtCardsFrame:Hide()
        player4dealtCardsFrame.playerCardsButton:Hide()
        player4dealtCardsFrameSplitH1:Show()
        player4dealtCardsFrameSplitH1.playerH1CardsButton:Show()
        player4dealtCardsFrameSplitH1.playerH2CardsButton:Show()
    end

end

-- Function to handle Player 4 PP Bet Image
function player4PlaceCoinsPPBet(message)
    playerFrame.player4PPBetCoins:Show()
end

-- Function to handle Player 4 PP Bet Text
function player4PlaceTextPPBet(message)
    player4HistoryPPBet = string.match(message, "(%d+)G")

        if player4HistoryPPBet then
            player4PPBetAmount:SetText(player4HistoryPPBet .. " G")
            player4PPBetAmount:Show()

            if playerName == unitName4 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName4]
                    player4totalBetAmount = player4totalBetAmount + tonumber(player4HistoryPPBet)
                    bankingInfo.totalWagered = player4totalBetAmount
                end
            end

            historyFrame.player4totalWageredAmount:SetText(player4totalBetAmount .. " G")

        else
    end
end

-- Function to handle Player 4 21+3 Bet Image
function player4PlaceCoins213Bet(message)
    playerFrame.player4213BetCoins:Show()
end

-- Function to handle Player 4 21+3 Bet Text
function player4PlaceText213Bet(message)
    player4History213Bet = string.match(message, "(%d+)G")

        if player4History213Bet then
            player4213BetAmount:SetText(player4History213Bet .. " G")
            player4213BetAmount:Show()

            if playerName == unitName4 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName4]
                    player4totalBetAmount = player4totalBetAmount + tonumber(player4History213Bet)
                    bankingInfo.totalWagered = player4totalBetAmount
                end
            end

            historyFrame.player4totalWageredAmount:SetText(player4totalBetAmount .. " G")

        else
    end
end

function player4PreloadBet()
    
    player4MainBet = tonumber(player4PreloadEditBoxMainBet:GetText()) or 0
    player4PPBet = tonumber(player4PreloadEditBoxPPBet:GetText()) or 0
    player4213Bet = tonumber(player4PreloadEditBox213Bet:GetText()) or 0

    player4TotalRebetAmount = player4MainBet + player4PPBet + player4213Bet

    player4currentBankroll = tonumber(string.match(bankrollFrame.player4TotalBankrollTableDisplay:GetText(), "%d+"))

    if player4currentBankroll - player4TotalRebetAmount < 0 then
        print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
    else
        player4Threshold = minBetMain - 1
        if player4MainBet <= player4Threshold then
            print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
        else
            if player4MainBet and player4MainBet >= minBetMain and player4MainBet <= maxBetMain then
                PlaySoundFile(soundFilePaths[33])
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P4] PIacing a " ..player4MainBet.. "G main bet.", "RAID")
                -- Disable the edit box and button
                player4PreloadEditBoxMainBet:SetFocus(false)
                player4PreloadEditBoxMainBet:ClearFocus()
                player4MainBetEditBox:SetText("")
                player4MainBetEditBox:SetText(player4MainBet)
                player4MainBetEditBox:SetFocus(false)
                player4MainBetEditBox:ClearFocus()
                player4MainBetEditBox:Disable()
                player4ConfirmMainBetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(player4MainBet)
                    bankingInfo.bankrollTable = player4TotalBankrollAmount
                end
            end

            if player4PPBet and player4PPBet >= minBetPP and player4PPBet <= maxBetPP then
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P4] PIacing a " ..player4PPBet.. "G side bet on Perfect Pairs.", "RAID")
                -- Disable the edit box and button
                player4PreloadEditBoxPPBet:SetFocus(false)
                player4PreloadEditBoxPPBet:ClearFocus()
                player4PPBetEditBox:SetText("")
                player4PPBetEditBox:SetText(player4PPBet)
                player4PPBetEditBox:SetFocus(false)
                player4PPBetEditBox:ClearFocus()
                player4PPBetEditBox:Disable()
                player4ConfirmPPBetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(player4PPBet)
                    bankingInfo.bankrollTable = player4TotalBankrollAmount
                end
            end

            if player4213Bet and player4213Bet >= minBet213 and player4213Bet <= maxBet213 then
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P4] PIacing a " ..player4213Bet.. "G side bet on 21+3.", "RAID")
                -- Disable the edit box and button
                player4PreloadEditBox213Bet:SetFocus(false)
                player4PreloadEditBox213Bet:ClearFocus()
                player4213BetEditBox:SetText("")
                player4213BetEditBox:SetText(player4213Bet)
                player4213BetEditBox:SetFocus(false)
                player4213BetEditBox:ClearFocus()
                player4213BetEditBox:Disable()
                player4Confirm213BetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(player4213Bet)
                    bankingInfo.bankrollTable = player4TotalBankrollAmount
                end
            end
            
            player4PreloadBetButton:Disable()

        end

        bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

    end

end

-- Function to handle the Player 1 Main "Bet" button click
function player4ConfirmMainBetClick()
    player4MainBet = tonumber(player4MainBetEditBox:GetText())
    player4currentBankroll = tonumber(string.match(bankrollFrame.player4TotalBankrollTableDisplay:GetText(), "%d+"))

    if player4MainBet and player4MainBet >= minBetMain and player4MainBet <= maxBetMain then
        if player4currentBankroll - player4MainBet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            -- Valid bet amount, send the message with the bet
            SendChatMessage("[P4] PIacing a " ..player4MainBet.. "G main bet.", "RAID")
            -- Disable the edit box and button
            player4MainBetEditBox:SetFocus(false)
            player4MainBetEditBox:ClearFocus()
            player4MainBetEditBox:Disable()
            player4ConfirmMainBetButton:Disable()

            player4PreloadBetButton:Disable()

            PlaySoundFile(soundFilePaths[33]) 

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(player4MainBet)
                bankingInfo.bankrollTable = player4TotalBankrollAmount
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBetMain .. "G and " .. maxBetMain .. "G.")
    end

end

-- Function to handle the Player 1 PP "Bet" button click
function player4ConfirmPPBetClick()
    player4PPBet = tonumber(player4PPBetEditBox:GetText()) -- Get the entered bet amount
    player4currentBankroll = tonumber(string.match(bankrollFrame.player4TotalBankrollTableDisplay:GetText(), "%d+"))

    if player4PPBet and player4PPBet >= minBetPP and player4PPBet <= maxBetPP then
        if player4currentBankroll - player4PPBet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            if not player4Active then
                print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
            else
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P4] PIacing a " ..player4PPBet.. "G side bet on Perfect Pairs.", "RAID")
                -- Disable the edit box and button
                player4PPBetEditBox:SetFocus(false)
                player4PPBetEditBox:ClearFocus()
                player4PPBetEditBox:Disable()
                player4ConfirmPPBetButton:Disable()

                player4PreloadBetButton:Disable()

                PlaySoundFile(soundFilePaths[33])

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(player4PPBet)
                    bankingInfo.bankrollTable = player4TotalBankrollAmount
                end

                bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
                cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

            end
        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBetPP .. "G and " .. maxBetPP .. "G.")
    end

end

-- Function to handle the Player 1 21+3 "Bet" button click
function player4Confirm213BetClick()
    player4213Bet = tonumber(player4213BetEditBox:GetText()) -- Get the entered bet amount
    player4currentBankroll = tonumber(string.match(bankrollFrame.player4TotalBankrollTableDisplay:GetText(), "%d+"))

    if player4213Bet and player4213Bet >= minBet213 and player4213Bet <= maxBet213 then
        if player4currentBankroll - player4213Bet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            if not player4Active then
                print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
            else
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P4] PIacing a " ..player4213Bet.. "G side bet on 21+3.", "RAID")
                -- Disable the edit box and button
                player4213BetEditBox:SetFocus(false)
                player4213BetEditBox:ClearFocus()
                player4213BetEditBox:Disable()
                player4Confirm213BetButton:Disable()

                player4PreloadBetButton:Disable()

                PlaySoundFile(soundFilePaths[33])

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(player4213Bet)
                    bankingInfo.bankrollTable = player4TotalBankrollAmount
                end

                bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
                cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

            end
        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBet213 .. "G and " .. maxBet213 .. "G.")
    end
 
end

-- Player 4 Main "Bet" button
player4ConfirmMainBetButton:SetScript("OnClick", player4ConfirmMainBetClick)

-- Player 4 PP "Bet" button
player4ConfirmPPBetButton:SetScript("OnClick", player4ConfirmPPBetClick)

-- Player 4 21+3 "Bet" button
player4Confirm213BetButton:SetScript("OnClick", player4Confirm213BetClick)

-- Player 4 "Bet All" Preload button
player4PreloadBetButton:SetScript("OnClick", player4PreloadBet)

function player4resetRaidChannel()
    if playerName == unitName4 then
        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/raid", chatFrame)
        
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:SetText("")
        editBox:Insert("/raid")
        
        ChatEdit_SendText(editBox)
        ChatEdit_DeactivateChat(editBox)
    else
        print("")
    end
end

player4HotstreakImage1 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage1:SetSize(36, 36)
player4HotstreakImage1:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak1.tga")
player4HotstreakImage1:SetDrawLayer("OVERLAY")
player4HotstreakImage1:Hide()

player4HotstreakImage2 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage2:SetSize(36, 36)
player4HotstreakImage2:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak2.tga")
player4HotstreakImage2:SetDrawLayer("OVERLAY")
player4HotstreakImage2:Hide()

player4HotstreakImage3 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage3:SetSize(36, 36)
player4HotstreakImage3:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak3.tga")
player4HotstreakImage3:SetDrawLayer("OVERLAY")
player4HotstreakImage3:Hide()

player4HotstreakImage4 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage4:SetSize(36, 36)
player4HotstreakImage4:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak4.tga")
player4HotstreakImage4:SetDrawLayer("OVERLAY")
player4HotstreakImage4:Hide()

player4HotstreakImage5 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage5:SetSize(36, 36)
player4HotstreakImage5:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak5.tga")
player4HotstreakImage5:SetDrawLayer("OVERLAY")
player4HotstreakImage5:Hide()

player4HotstreakImage6 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage6:SetSize(36, 36)
player4HotstreakImage6:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak6.tga")
player4HotstreakImage6:SetDrawLayer("OVERLAY")
player4HotstreakImage6:Hide()

player4HotstreakImage7 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage7:SetSize(36, 36)
player4HotstreakImage7:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak7.tga")
player4HotstreakImage7:SetDrawLayer("OVERLAY")
player4HotstreakImage7:Hide()

player4HotstreakImage8 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage8:SetSize(36, 36)
player4HotstreakImage8:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage8:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak8.tga")
player4HotstreakImage8:SetDrawLayer("OVERLAY")
player4HotstreakImage8:Hide()

player4HotstreakImage9 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage9:SetSize(36, 36)
player4HotstreakImage9:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage9:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak9.tga")
player4HotstreakImage9:SetDrawLayer("OVERLAY")
player4HotstreakImage9:Hide()

player4HotstreakImage10 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage10:SetSize(36, 36)
player4HotstreakImage10:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage10:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak10.tga")
player4HotstreakImage10:SetDrawLayer("OVERLAY")
player4HotstreakImage10:Hide()

player4HotstreakImage11 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage11:SetSize(36, 36)
player4HotstreakImage11:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage11:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak11.tga")
player4HotstreakImage11:SetDrawLayer("OVERLAY")
player4HotstreakImage11:Hide()

player4HotstreakImage12 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage12:SetSize(36, 36)
player4HotstreakImage12:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage12:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak12.tga")
player4HotstreakImage12:SetDrawLayer("OVERLAY")
player4HotstreakImage12:Hide()

player4HotstreakImage13 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage13:SetSize(36, 36)
player4HotstreakImage13:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage13:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak13.tga")
player4HotstreakImage13:SetDrawLayer("OVERLAY")
player4HotstreakImage13:Hide()

player4HotstreakImage14 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage14:SetSize(36, 36)
player4HotstreakImage14:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage14:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak14.tga")
player4HotstreakImage14:SetDrawLayer("OVERLAY")
player4HotstreakImage14:Hide()

player4HotstreakImage15 = playerFrame:CreateTexture(nil, "OVERLAY")
player4HotstreakImage15:SetSize(36, 36)
player4HotstreakImage15:SetPoint("CENTER", playerFrame, -339, -223)
player4HotstreakImage15:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak15.tga")
player4HotstreakImage15:SetDrawLayer("OVERLAY")
player4HotstreakImage15:Hide()

function player4HotStreakCheck()
    if player4Hotstreak == 0 then
        player4HotstreakImage1:Hide()
        player4HotstreakImage2:Hide()
        player4HotstreakImage3:Hide()
        player4HotstreakImage4:Hide()
        player4HotstreakImage5:Hide()
        player4HotstreakImage6:Hide()
        player4HotstreakImage7:Hide()
        player4HotstreakImage8:Hide()
        player4HotstreakImage9:Hide()
        player4HotstreakImage10:Hide()
        player4HotstreakImage11:Hide()
        player4HotstreakImage12:Hide()
        player4HotstreakImage13:Hide()
        player4HotstreakImage14:Hide()
        player4HotstreakImage15:Hide()
    elseif player4Hotstreak == 1 then
        player4HotstreakImage1:Show()
    elseif player4Hotstreak == 2 then
        player4HotstreakImage1:Hide()
        player4HotstreakImage2:Show()
    elseif player4Hotstreak == 3 then
        player4HotstreakImage1:Hide()
        player4HotstreakImage2:Hide()
        player4HotstreakImage3:Show()
    elseif player4Hotstreak == 4 then
        player4HotstreakImage2:Hide()
        player4HotstreakImage3:Hide()
        player4HotstreakImage4:Show()
    elseif player4Hotstreak == 5 then
        player4HotstreakImage3:Hide()
        player4HotstreakImage4:Hide()
        player4HotstreakImage5:Show()
    elseif player4Hotstreak == 6 then
        player4HotstreakImage4:Hide()
        player4HotstreakImage5:Hide()
        player4HotstreakImage6:Show()
    elseif player4Hotstreak == 7 then
        player4HotstreakImage5:Hide()
        player4HotstreakImage6:Hide()
        player4HotstreakImage7:Show()
    elseif player4Hotstreak == 8 then
        player4HotstreakImage6:Hide()
        player4HotstreakImage7:Hide()
        player4HotstreakImage8:Show()
    elseif player4Hotstreak == 9 then
        player4HotstreakImage7:Hide()
        player4HotstreakImage8:Hide()
        player4HotstreakImage9:Show()
    elseif player4Hotstreak == 10 then
        player4HotstreakImage8:Hide()
        player4HotstreakImage9:Hide()
        player4HotstreakImage10:Show()
    elseif player4Hotstreak == 11 then
        player4HotstreakImage9:Hide()
        player4HotstreakImage10:Hide()
        player4HotstreakImage11:Show()
    elseif player4Hotstreak == 12 then
        player4HotstreakImage10:Hide()
        player4HotstreakImage11:Hide()
        player4HotstreakImage12:Show()
    elseif player4Hotstreak == 13 then
        player4HotstreakImage11:Hide()
        player4HotstreakImage12:Hide()
        player4HotstreakImage13:Show()
    elseif player4Hotstreak == 14 then
        player4HotstreakImage12:Hide()
        player4HotstreakImage13:Hide()
        player4HotstreakImage14:Show()
    elseif player4Hotstreak == 15 then
        player4HotstreakImage13:Hide()
        player4HotstreakImage14:Hide()
        player4HotstreakImage15:Show()
    end
end

-- Function to handle Player 4 PP Win Image
function player4PlaceBetsPPWin(message)
    playerFrame.player4PPBetCoins:Hide()
    playerFrame.player4PPWinCoins:Show()
    player4PPBetAmount:SetPoint("CENTER", playerFrame, -219, 43)
end

-- Function to handle Player 4 21+3 Win Image
function player4PlaceBets213Win(message)
    playerFrame.player4213BetCoins:Hide()
    playerFrame.player4213WinCoins:Show()
    player4213BetAmount:SetPoint("CENTER", playerFrame, -107, -8)
end

function player4MixedPairWin(message)

    if playerName == unitName4 then
        player4PPBetAmountValue = tonumber(string.match(player4PPBetEditBox:GetText(), "%d+"))
        if player4PPBetAmountValue then
            player4NewPPAmount = player4PPBetAmountValue * mixedPairPayoutReturn
            player4PPBetAmount:SetText(player4NewPPAmount .. " G")
            player4PPBetAmount:SetTextColor(0, 1, 0)

            player4PPProfitvalue = player4NewPPAmount - player4PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player4totalWin = player4totalWin + tonumber(player4PPProfitvalue)
                    bankingInfo.totalWon = player4totalWin
                    player4totalProfit = player4totalProfit + tonumber(player4PPProfitvalue)
                    bankingInfo.totalProfit = player4totalProfit
                    player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4NewPPAmount)
                    bankingInfo.bankrollTable = player4TotalBankrollAmount
                end

            historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
            historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
            if player4totalProfit >= 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        end
    else
        player4PPBetAmountValue = tonumber(string.match(player4PPBetAmount:GetText(), "%d+"))
        if player4PPBetAmountValue then
            player4NewPPAmount = player4PPBetAmountValue * mixedPairPayoutReturn
            player4PPBetAmount:SetText(player4NewPPAmount .. " G")
            player4PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player4PlaceBetsPPWin()
    player4PPSideBetWin = true

    player4SessionWin = player4SessionWin + tonumber(player4NewPPAmount)

end

function player4ColouredPairWin(message)

    if playerName == unitName4 then
        player4PPBetAmountValue = tonumber(string.match(player4PPBetEditBox:GetText(), "%d+"))
        if player4PPBetAmountValue then
            player4NewPPAmount = player4PPBetAmountValue * colouredPairPayoutReturn
            player4PPBetAmount:SetText(player4NewPPAmount .. " G")
            player4PPBetAmount:SetTextColor(0, 1, 0)

            player4PPProfitvalue = player4NewPPAmount - player4PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player4totalWin = player4totalWin + tonumber(player4PPProfitvalue)
                    bankingInfo.totalWon = player4totalWin
                    player4totalProfit = player4totalProfit + tonumber(player4PPProfitvalue)
                    bankingInfo.totalProfit = player4totalProfit
                    player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4NewPPAmount)
                    bankingInfo.bankrollTable = player4TotalBankrollAmount
                end

            historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
            historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
            if player4totalProfit >= 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        end
    else
        player4PPBetAmountValue = tonumber(string.match(player4PPBetAmount:GetText(), "%d+"))
        if player4PPBetAmountValue then
            player4NewPPAmount = player4PPBetAmountValue * colouredPairPayoutReturn
            player4PPBetAmount:SetText(player4NewPPAmount .. " G")
            player4PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player4PlaceBetsPPWin()
    player4PPSideBetWin = true

    player4SessionWin = player4SessionWin + tonumber(player4NewPPAmount)

end

function player4PerfectPairWin(message)

    if playerName == unitName4 then
        player4PPBetAmountValue = tonumber(string.match(player4PPBetEditBox:GetText(), "%d+"))
        if player4PPBetAmountValue then
            player4NewPPAmount = player4PPBetAmountValue * perfectPairPayoutReturn
            player4PPBetAmount:SetText(player4NewPPAmount .. " G")
            player4PPBetAmount:SetTextColor(0, 1, 0)

            player4PPProfitvalue = player4NewPPAmount - player4PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player4totalWin = player4totalWin + tonumber(player4PPProfitvalue)
                    bankingInfo.totalWon = player4totalWin
                    player4totalProfit = player4totalProfit + tonumber(player4PPProfitvalue)
                    bankingInfo.totalProfit = player4totalProfit
                    player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4NewPPAmount)
                    bankingInfo.bankrollTable = player4TotalBankrollAmount
                end

            historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
            historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
            if player4totalProfit >= 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        end
    else
        player4PPBetAmountValue = tonumber(string.match(player4PPBetAmount:GetText(), "%d+"))
        if player4PPBetAmountValue then
            player4NewPPAmount = player4PPBetAmountValue * perfectPairPayoutReturn
            player4PPBetAmount:SetText(player4NewPPAmount .. " G")
            player4PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player4PlaceBetsPPWin()
    player4PPSideBetWin = true

    player4SessionWin = player4SessionWin + tonumber(player4NewPPAmount)

end

function player4SuitedThreeOfAKindWin(message)

    if playerName == unitName4 then
        player4213BetAmountValue = tonumber(string.match(player4213BetEditBox:GetText(), "%d+"))
        if player4213BetAmountValue then
            player4New213Amount = player4213BetAmountValue * suitedThreeOfAKindPayoutReturn
            player4213BetAmount:SetText(player4New213Amount .. " G")
            player4213BetAmount:SetTextColor(0, 1, 0)

            player4213Profitvalue = player4New213Amount - player4213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4totalWin = player4totalWin + tonumber(player4213Profitvalue)
                bankingInfo.totalWon = player4totalWin
                player4totalProfit = player4totalProfit + tonumber(player4213Profitvalue)
                bankingInfo.totalProfit = player4totalProfit
                player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4New213Amount)
                bankingInfo.bankrollTable = player4TotalBankrollAmount
            end

            historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
            historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
            if player4totalProfit >= 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        end
    else
        player4213BetAmountValue = tonumber(string.match(player4213BetAmount:GetText(), "%d+"))
        if player4213BetAmountValue then
            player4New213Amount = player4213BetAmountValue * suitedThreeOfAKindPayoutReturn
            player4213BetAmount:SetText(player4New213Amount .. " G")
            player4213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player4PlaceBets213Win()
    player4213SideBetWin = true

    player4SessionWin = player4SessionWin + tonumber(player4New213Amount)

end

function player4StraightFlushWin(message)
    
    if playerName == unitName4 then
        player4213BetAmountValue = tonumber(string.match(player4213BetEditBox:GetText(), "%d+"))
        if player4213BetAmountValue then
            player4New213Amount = player4213BetAmountValue * straightFlushPayoutReturn
            player4213BetAmount:SetText(player4New213Amount .. " G")
            player4213BetAmount:SetTextColor(0, 1, 0)

            player4213Profitvalue = player4New213Amount - player4213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4totalWin = player4totalWin + tonumber(player4213Profitvalue)
                bankingInfo.totalWon = player4totalWin
                player4totalProfit = player4totalProfit + tonumber(player4213Profitvalue)
                bankingInfo.totalProfit = player4totalProfit
                player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4New213Amount)
                bankingInfo.bankrollTable = player4TotalBankrollAmount
            end

            historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
            historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
            if player4totalProfit >= 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        end
    else
        player4213BetAmountValue = tonumber(string.match(player4213BetAmount:GetText(), "%d+"))
        if player4213BetAmountValue then
            player4New213Amount = player4213BetAmountValue * straightFlushPayoutReturn
            player4213BetAmount:SetText(player4New213Amount .. " G")
            player4213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player4PlaceBets213Win()
    player4213SideBetWin = true

    player4SessionWin = player4SessionWin + tonumber(player4New213Amount)

end

function player4ThreeOfAKindWin(message)

    if playerName == unitName4 then
        player4213BetAmountValue = tonumber(string.match(player4213BetEditBox:GetText(), "%d+"))
        if player4213BetAmountValue then
            player4New213Amount = player4213BetAmountValue * threeOfAKindPayoutReturn
            player4213BetAmount:SetText(player4New213Amount .. " G")
            player4213BetAmount:SetTextColor(0, 1, 0)

            player4213Profitvalue = player4New213Amount - player4213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4totalWin = player4totalWin + tonumber(player4213Profitvalue)
                bankingInfo.totalWon = player4totalWin
                player4totalProfit = player4totalProfit + tonumber(player4213Profitvalue)
                bankingInfo.totalProfit = player4totalProfit
                player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4New213Amount)
                bankingInfo.bankrollTable = player4TotalBankrollAmount
            end

            historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
            historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
            if player4totalProfit >= 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        end
    else
        player4213BetAmountValue = tonumber(string.match(player4213BetAmount:GetText(), "%d+"))
        if player4213BetAmountValue then
            player4New213Amount = player4213BetAmountValue * threeOfAKindPayoutReturn
            player4213BetAmount:SetText(player4New213Amount .. " G")
            player4213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player4PlaceBets213Win()
    player4213SideBetWin = true

    player4SessionWin = player4SessionWin + tonumber(player4New213Amount)

end

function player4StraightWin(message)

    if playerName == unitName4 then
        player4213BetAmountValue = tonumber(string.match(player4213BetEditBox:GetText(), "%d+"))
        if player4213BetAmountValue then
            player4New213Amount = player4213BetAmountValue * straightPayoutReturn
            player4213BetAmount:SetText(player4New213Amount .. " G")
            player4213BetAmount:SetTextColor(0, 1, 0)

            player4213Profitvalue = player4New213Amount - player4213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4totalWin = player4totalWin + tonumber(player4213Profitvalue)
                bankingInfo.totalWon = player4totalWin
                player4totalProfit = player4totalProfit + tonumber(player4213Profitvalue)
                bankingInfo.totalProfit = player4totalProfit
                player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4New213Amount)
                bankingInfo.bankrollTable = player4TotalBankrollAmount
            end

            historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
            historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
            if player4totalProfit >= 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        end
    else
        player4213BetAmountValue = tonumber(string.match(player4213BetAmount:GetText(), "%d+"))
        if player4213BetAmountValue then
            player4New213Amount = player4213BetAmountValue * straightPayoutReturn
            player4213BetAmount:SetText(player4New213Amount .. " G")
            player4213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player4PlaceBets213Win()
    player4213SideBetWin = true

    player4SessionWin = player4SessionWin + tonumber(player4New213Amount)

end

function player4FlushWin(message)

    if playerName == unitName4 then
        player4213BetAmountValue = tonumber(string.match(player4213BetEditBox:GetText(), "%d+"))
        if player4213BetAmountValue then
            player4New213Amount = player4213BetAmountValue * flushPayoutReturn
            player4213BetAmount:SetText(player4New213Amount .. " G")
            player4213BetAmount:SetTextColor(0, 1, 0)

            player4213Profitvalue = player4New213Amount - player4213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4totalWin = player4totalWin + tonumber(player4213Profitvalue)
                bankingInfo.totalWon = player4totalWin
                player4totalProfit = player4totalProfit + tonumber(player4213Profitvalue)
                bankingInfo.totalProfit = player4totalProfit
                player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4New213Amount)
                bankingInfo.bankrollTable = player4TotalBankrollAmount
            end

            historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
            historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
            if player4totalProfit >= 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        end
    else
        player4213BetAmountValue = tonumber(string.match(player4213BetAmount:GetText(), "%d+"))
        if player4213BetAmountValue then
            player4New213Amount = player4213BetAmountValue * flushPayoutReturn
            player4213BetAmount:SetText(player4New213Amount .. " G")
            player4213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player4PlaceBets213Win()
    player4213SideBetWin = true

    player4SessionWin = player4SessionWin + tonumber(player4New213Amount)

end

function player4Loss()
    player4MainBetValue = tonumber(string.match(player4MainBetAmount:GetText(), "%d+"))
    if player4MainBetValue then
        
        if playerName == unitName4 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4totalLoss = player4totalLoss + tonumber(player4MainBetValue)
                bankingInfo.totalLost = player4totalLoss
                player4totalProfit = player4totalProfit - tonumber(player4MainBetValue)
                bankingInfo.totalProfit = player4totalProfit
            end
        end

        if player4totalProfit >= 0 then
            historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

        historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
        historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")

        player4PPBetText = player4PPBetAmount:GetText()

        if player4PPBetText and player4PPBetText ~= "" then
            player4PPBetAmountValue = tonumber(string.match(player4PPBetText, "%d+"))
            
            if player4PPBetAmountValue then
                if player4PPSideBetWin == false then

                    player4PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName4 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player4totalLoss = player4totalLoss + tonumber(player4PPBetAmountValue)
                            bankingInfo.totalLost = player4totalLoss
                            player4totalProfit = player4totalProfit - tonumber(player4PPBetAmountValue)
                            bankingInfo.totalProfit = player4totalProfit
                        end
                    end
            
                    if player4totalProfit >= 0 then
                        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end
            
                    historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")

                end
            end
        end

        player4213BetText = player4213BetAmount:GetText()

        if player4213BetText and player4213BetText ~= "" then
            player4213BetAmountValue = tonumber(string.match(player4213BetText, "%d+"))

            if player4213BetAmountValue then
                if player4213SideBetWin == false then

                    player4213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName4 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player4totalLoss = player4totalLoss + tonumber(player4213BetAmountValue)
                            bankingInfo.totalLost = player4totalLoss
                            player4totalProfit = player4totalProfit - tonumber(player4213BetAmountValue)
                            bankingInfo.totalProfit = player4totalProfit
                        end
                    end
            
                    if player4totalProfit >= 0 then
                        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end
            
                    historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")

                end
            end
        end
    end
end

function player4SplitH1Loss()
    player4SplitHand1BetAmountValue = tonumber(string.match(player4SplitH1BetAmount:GetText(), "%d+"))
    if player4SplitHand1BetAmountValue then

        if playerName == unitName4 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4totalLoss = player4totalLoss + tonumber(player4SplitHand1BetAmountValue)
                bankingInfo.totalLost = player4totalLoss
                player4totalProfit = player4totalProfit - tonumber(player4SplitHand1BetAmountValue)
                bankingInfo.totalProfit = player4totalProfit
            end
        end

        historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
        historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")

        if player4totalProfit >= 0 then
            historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

    end
end

function player4SplitH2Loss()
    player4SplitHand2BetAmountValue = tonumber(string.match(player4SplitH2BetAmount:GetText(), "%d+"))
    if player4SplitHand2BetAmountValue then

        if playerName == unitName4 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4totalLoss = player4totalLoss + tonumber(player4SplitHand2BetAmountValue)
                bankingInfo.totalLost = player4totalLoss
                player4totalProfit = player4totalProfit - tonumber(player4SplitHand2BetAmountValue)
                bankingInfo.totalProfit = player4totalProfit
            end
        end

        historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
        historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")

        if player4totalProfit >= 0 then
            historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

        player4PPBetText = player4PPBetAmount:GetText()

        if player4PPBetText and player4PPBetText ~= "" then
            player4PPBetAmountValue = tonumber(string.match(player4PPBetText, "%d+"))
            
            if player4PPBetAmountValue then
                if player4PPSideBetWin == false then

                    player4PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName4 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player4totalLoss = player4totalLoss + tonumber(player4PPBetAmountValue)
                            bankingInfo.totalLost = player4totalLoss
                            player4totalProfit = player4totalProfit - tonumber(player4PPBetAmountValue)
                            bankingInfo.totalProfit = player4totalProfit
                        end
                    end
            
                    historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
                    if player4totalProfit >= 0 then
                        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player4213BetText = player4213BetAmount:GetText()

        if player4213BetText and player4213BetText ~= "" then
            player4213BetAmountValue = tonumber(string.match(player4213BetText, "%d+"))

            if player4213BetAmountValue then
                if player4213SideBetWin == false then

                    player4213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName4 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player4totalLoss = player4totalLoss + tonumber(player4213BetAmountValue)
                            bankingInfo.totalLost = player4totalLoss
                            player4totalProfit = player4totalProfit - tonumber(player4213BetAmountValue)
                            bankingInfo.totalProfit = player4totalProfit
                        end
                    end
            
                    historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
                    if player4totalProfit >= 0 then
                        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

function player4Push()
    player4MainBetValue = tonumber(string.match(player4MainBetAmount:GetText(), "%d+"))
    if player4MainBetValue then


        if playerName == unitName4 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4MainBetValue)
                bankingInfo.bankrollTable = player4TotalBankrollAmount
            end
        end

        bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

        player4PPBetText = player4PPBetAmount:GetText()

        if player4PPBetText and player4PPBetText ~= "" then
            player4PPBetAmountValue = tonumber(string.match(player4PPBetText, "%d+"))
            
            if player4PPBetAmountValue then
                if player4PPSideBetWin == false then

                    player4PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName4 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player4totalLoss = player4totalLoss + tonumber(player4PPBetAmountValue)
                            bankingInfo.totalLost = player4totalLoss
                            player4totalProfit = player4totalProfit - tonumber(player4PPBetAmountValue)
                            bankingInfo.totalProfit = player4totalProfit
                        end
                    end
            
                    historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
                    if player4totalProfit >= 0 then
                        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player4213BetText = player4213BetAmount:GetText()

        if player4213BetText and player4213BetText ~= "" then
            player4213BetAmountValue = tonumber(string.match(player4213BetText, "%d+"))

            if player4213BetAmountValue then
                if player4213SideBetWin == false then

                    player4213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName4 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player4totalLoss = player4totalLoss + tonumber(player4213BetAmountValue)
                            bankingInfo.totalLost = player4totalLoss
                            player4totalProfit = player4totalProfit - tonumber(player4213BetAmountValue)
                            bankingInfo.totalProfit = player4totalProfit
                        end
                    end
            
                    historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
                    if player4totalProfit >= 0 then
                        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player4SessionWin = player4SessionWin + tonumber(player4MainBetValue)

    end
end

function player4SplitH1Push()
    player4SplitHand1BetAmountValue = tonumber(string.match(player4SplitH1BetAmount:GetText(), "%d+"))
    if player4SplitHand1BetAmountValue then

        if playerName == unitName4 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4SplitHand1BetAmountValue)
                bankingInfo.bankrollTable = player4TotalBankrollAmount
            end
        end

        bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
    
        player4SessionWin = player4SessionWin + tonumber(player4SplitHand1BetAmountValue)
    
    end
end

function player4SplitH2Push()
    player4SplitHand2BetAmountValue = tonumber(string.match(player4SplitH2BetAmount:GetText(), "%d+"))
    if player4SplitHand2BetAmountValue then

        if playerName == unitName4 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4SplitHand2BetAmountValue)
                bankingInfo.bankrollTable = player4TotalBankrollAmount
            end
        end

        bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

        player4PPBetText = player4PPBetAmount:GetText()

        if player4PPBetText and player4PPBetText ~= "" then
            player4PPBetAmountValue = tonumber(string.match(player4PPBetText, "%d+"))
            
            if player4PPBetAmountValue then
                if player4PPSideBetWin == false then

                    player4PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName4 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player4totalLoss = player4totalLoss + tonumber(player4PPBetAmountValue)
                            bankingInfo.totalLost = player4totalLoss
                            player4totalProfit = player4totalProfit - tonumber(player4PPBetAmountValue)
                            bankingInfo.totalProfit = player4totalProfit
                        end
                    end
            
                    historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
                    if player4totalProfit >= 0 then
                        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player4213BetText = player4213BetAmount:GetText()

        if player4213BetText and player4213BetText ~= "" then
            player4213BetAmountValue = tonumber(string.match(player4213BetText, "%d+"))

            if player4213BetAmountValue then
                if player4213SideBetWin == false then

                    player4213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName4 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player4totalLoss = player4totalLoss + tonumber(player4213BetAmountValue)
                            bankingInfo.totalLost = player4totalLoss
                            player4totalProfit = player4totalProfit - tonumber(player4213BetAmountValue)
                            bankingInfo.totalProfit = player4totalProfit
                        end
                    end
            
                    historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
                    if player4totalProfit >= 0 then
                        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    
        player4SessionWin = player4SessionWin + tonumber(player4SplitHand2BetAmountValue)
    
    end
end

function player4BJWin(message)
    player4MainBetAmountValue = tonumber(string.match(player4MainBetAmount:GetText(), "%d+"))
    if player4MainBetAmountValue then
        player4BJWinAmountValue = player4MainBetAmountValue * 2.5
        player4MainBetAmount:SetText(player4BJWinAmountValue .. " G")
    end

    player4BJProfitvalue = player4BJWinAmountValue - player4MainBetAmountValue

    if playerName == unitName4 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player4totalWin = player4totalWin + tonumber(player4BJProfitvalue)
            bankingInfo.totalWon = player4totalWin
            player4totalProfit = player4totalProfit + tonumber(player4BJProfitvalue)
            bankingInfo.totalProfit = player4totalProfit
            player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4BJWinAmountValue)
            bankingInfo.bankrollTable = player4TotalBankrollAmount
        end
    end

    if player4totalProfit >= 0 then
        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
    bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
    cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

    player4PPBetText = player4PPBetAmount:GetText()

    if player4PPBetText and player4PPBetText ~= "" then
        player4PPBetAmountValue = tonumber(string.match(player4PPBetText, "%d+"))
        
        if player4PPBetAmountValue then
            if player4PPSideBetWin == false then

                player4PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName4 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player4totalLoss = player4totalLoss + tonumber(player4PPBetAmountValue)
                        bankingInfo.totalLost = player4totalLoss
                        player4totalProfit = player4totalProfit - tonumber(player4PPBetAmountValue)
                        bankingInfo.totalProfit = player4totalProfit
                    end
                end
        
                historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
        
                if player4totalProfit >= 0 then
                    historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player4213BetText = player4213BetAmount:GetText()

    if player4213BetText and player4213BetText ~= "" then
        player4213BetAmountValue = tonumber(string.match(player4213BetText, "%d+"))

        if player4213BetAmountValue then
            if player4213SideBetWin == false then

                player4213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName4 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player4totalLoss = player4totalLoss + tonumber(player4213BetAmountValue)
                        bankingInfo.totalLost = player4totalLoss
                        player4totalProfit = player4totalProfit - tonumber(player4213BetAmountValue)
                        bankingInfo.totalProfit = player4totalProfit
                    end
                end
        
                historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
        
                if player4totalProfit >= 0 then
                    historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player4MainBetCoins:Hide()
    playerFrame.player4BJWinCoins:Show()

    player4SessionWin = player4SessionWin + tonumber(player4BJWinAmountValue)

end

function player4SplitH1BJ(message)
    player4SplitHand1BetAmountValue = tonumber(string.match(player4SplitH1BetAmount:GetText(), "%d+"))
    if player4SplitHand1BetAmountValue then
        player4SplitHand1BJWinAmountValue = player4SplitHand1BetAmountValue * 2.5
        player4SplitH1BetAmount:SetText(player4SplitHand1BJWinAmountValue .. " G")
    end

    player4SplitHand1BJProfitValue = player4SplitHand1BJWinAmountValue - player4SplitHand1BetAmountValue

    if playerName == unitName4 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player4totalWin = player4totalWin + tonumber(player4SplitHand1BJProfitValue)
            bankingInfo.totalWon = player4totalWin
            player4totalProfit = player4totalProfit + tonumber(player4SplitHand1BJProfitValue)
            bankingInfo.totalProfit = player4totalProfit
            player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4SplitHand1BJWinAmountValue)
            bankingInfo.bankrollTable = player4TotalBankrollAmount
        end
    end

    if player4totalProfit >= 0 then
        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
    bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
    cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

    playerFrame.player4SplitHand1Coins:Hide()
    playerFrame.player4SplitHand1BJWinCoins:Show()

    player4SessionWin = player4SessionWin + tonumber(player4SplitHand1BJWinAmountValue)

end

function player4SplitH2BJ(message)
    player4SplitHand2BetAmountValue = tonumber(string.match(player4SplitH2BetAmount:GetText(), "%d+"))
    if player4SplitHand2BetAmountValue then
        player4SplitHand2BJWinAmountValue = player4SplitHand2BetAmountValue * 2.5
        player4SplitH2BetAmount:SetText(player4SplitHand2BJWinAmountValue .. " G")
    end

    player4SplitHand2BJProfitValue = player4SplitHand2BJWinAmountValue - player4SplitHand2BetAmountValue

    if playerName == unitName4 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player4totalWin = player4totalWin + tonumber(player4SplitHand2BJProfitValue)
            bankingInfo.totalWon = player4totalWin
            player4totalProfit = player4totalProfit + tonumber(player4SplitHand2BJProfitValue)
            bankingInfo.totalProfit = player4totalProfit
            player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4SplitHand2BJWinAmountValue)
            bankingInfo.bankrollTable = player4TotalBankrollAmount
        end
    end

    if player4totalProfit >= 0 then
        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
    bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
    cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

    player4PPBetText = player4PPBetAmount:GetText()

    if player4PPBetText and player4PPBetText ~= "" then
        player4PPBetAmountValue = tonumber(string.match(player4PPBetText, "%d+"))
        
        if player4PPBetAmountValue then
            if player4PPSideBetWin == false then

                player4PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName4 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player4totalLoss = player4totalLoss + tonumber(player4PPBetAmountValue)
                        bankingInfo.totalLost = player4totalLoss
                        player4totalProfit = player4totalProfit - tonumber(player4PPBetAmountValue)
                        bankingInfo.totalProfit = player4totalProfit
                    end
                end
        
                historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
        
                if player4totalProfit >= 0 then
                    historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player4213BetText = player4213BetAmount:GetText()

    if player4213BetText and player4213BetText ~= "" then
        player4213BetAmountValue = tonumber(string.match(player4213BetText, "%d+"))

        if player4213BetAmountValue then
            if player4213SideBetWin == false then

                player4213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName4 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player4totalLoss = player4totalLoss + tonumber(player4213BetAmountValue)
                        bankingInfo.totalLost = player4totalLoss
                        player4totalProfit = player4totalProfit - tonumber(player4213BetAmountValue)
                        bankingInfo.totalProfit = player4totalProfit
                    end
                end
        
                historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
        
                if player4totalProfit >= 0 then
                    historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player4SplitHand2Coins:Hide()
    playerFrame.player4SplitHand2BJWinCoins:Show()

    player4SessionWin = player4SessionWin + tonumber(player4SplitHand2BJWinAmountValue)

end

function player4Win(message)
    player4MainBetAmountValue = tonumber(string.match(player4MainBetAmount:GetText(), "%d+"))
    if player4MainBetAmountValue then
        player4NormalWinAmountValue = player4MainBetAmountValue * 2
        player4MainBetAmount:SetText(player4NormalWinAmountValue .. " G")

        if playerName == unitName4 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player4totalWin = player4totalWin + tonumber(player4MainBetAmountValue)
                bankingInfo.totalWon = player4totalWin
                player4totalProfit = player4totalProfit + tonumber(player4MainBetAmountValue)
                bankingInfo.totalProfit = player4totalProfit
                player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4NormalWinAmountValue)
                bankingInfo.bankrollTable = player4TotalBankrollAmount
            end
        end
    
        if player4totalProfit >= 0 then
            historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end
    
        historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
        historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
        bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

        player4PPBetText = player4PPBetAmount:GetText()

        if player4PPBetText and player4PPBetText ~= "" then
            player4PPBetAmountValue = tonumber(string.match(player4PPBetText, "%d+"))
            
            if player4PPBetAmountValue then
                if player4PPSideBetWin == false then

                    player4PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName4 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player4totalLoss = player4totalLoss + tonumber(player4PPBetAmountValue)
                            bankingInfo.totalLost = player4totalLoss
                            player4totalProfit = player4totalProfit - tonumber(player4PPBetAmountValue)
                            bankingInfo.totalProfit = player4totalProfit
                        end
                    end
            
                    historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
                    if player4totalProfit >= 0 then
                        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player4213BetText = player4213BetAmount:GetText()

        if player4213BetText and player4213BetText ~= "" then
            player4213BetAmountValue = tonumber(string.match(player4213BetText, "%d+"))

            if player4213BetAmountValue then
                if player4213SideBetWin == false then

                    player4213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName4 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player4totalLoss = player4totalLoss + tonumber(player4213BetAmountValue)
                            bankingInfo.totalLost = player4totalLoss
                            player4totalProfit = player4totalProfit - tonumber(player4213BetAmountValue)
                            bankingInfo.totalProfit = player4totalProfit
                        end
                    end
            
                    historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            
                    if player4totalProfit >= 0 then
                        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end

    playerFrame.player4MainBetCoins:Hide()
    playerFrame.player4NormalWinCoins:Show()

    player4SessionWin = player4SessionWin + tonumber(player4NormalWinAmountValue)

end

function player4SplitH1Win(message)
    player4SplitHand1BetAmountValue = tonumber(string.match(player4SplitH1BetAmount:GetText(), "%d+"))
    if player4SplitHand1BetAmountValue then
        player4SplitHand1NormalWinAmountValue = player4SplitHand1BetAmountValue * 2
        player4SplitH1BetAmount:SetText(player4SplitHand1NormalWinAmountValue .. " G")
    end

    if playerName == unitName4 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player4totalWin = player4totalWin + tonumber(player4SplitHand1BetAmountValue)
            bankingInfo.totalWon = player4totalWin
            player4totalProfit = player4totalProfit + tonumber(player4SplitHand1BetAmountValue)
            bankingInfo.totalProfit = player4totalProfit
            player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4SplitHand1NormalWinAmountValue)
            bankingInfo.bankrollTable = player4TotalBankrollAmount
        end
    end

    if player4totalProfit >= 0 then
        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
    bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
    cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

    playerFrame.player4SplitHand1Coins:Hide()
    playerFrame.player4SplitHand1NormalWinCoins:Show()

    player4SessionWin = player4SessionWin + tonumber(player4SplitHand1NormalWinAmountValue)

end

function player4SplitH2Win(message)
    player4SplitHand2BetAmountValue = tonumber(string.match(player4SplitH2BetAmount:GetText(), "%d+"))
    if player4SplitHand2BetAmountValue then
        player4SplitHand2NormalWinAmountValue = player4SplitHand2BetAmountValue * 2
        player4SplitH2BetAmount:SetText(player4SplitHand2NormalWinAmountValue .. " G")
    end

    if playerName == unitName4 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player4totalWin = player4totalWin + tonumber(player4SplitHand2BetAmountValue)
            bankingInfo.totalWon = player4totalWin
            player4totalProfit = player4totalProfit + tonumber(player4SplitHand2BetAmountValue)
            bankingInfo.totalProfit = player4totalProfit
            player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4SplitHand2NormalWinAmountValue)
            bankingInfo.bankrollTable = player4TotalBankrollAmount
        end
    end

    if player4totalProfit >= 0 then
        historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
    historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
    bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
    cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

    player4PPBetText = player4PPBetAmount:GetText()

    if player4PPBetText and player4PPBetText ~= "" then
        player4PPBetAmountValue = tonumber(string.match(player4PPBetText, "%d+"))
        
        if player4PPBetAmountValue then
            if player4PPSideBetWin == false then

                player4PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName4 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player4totalLoss = player4totalLoss + tonumber(player4PPBetAmountValue)
                        bankingInfo.totalLost = player4totalLoss
                        player4totalProfit = player4totalProfit - tonumber(player4PPBetAmountValue)
                        bankingInfo.totalProfit = player4totalProfit
                    end
                end
        
                historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
        
                if player4totalProfit >= 0 then
                    historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player4213BetText = player4213BetAmount:GetText()

    if player4213BetText and player4213BetText ~= "" then
        player4213BetAmountValue = tonumber(string.match(player4213BetText, "%d+"))

        if player4213BetAmountValue then
            if player4213SideBetWin == false then

                player4213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName4 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player4totalLoss = player4totalLoss + tonumber(player4213BetAmountValue)
                        bankingInfo.totalLost = player4totalLoss
                        player4totalProfit = player4totalProfit - tonumber(player4213BetAmountValue)
                        bankingInfo.totalProfit = player4totalProfit
                    end
                end
        
                historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
                historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
        
                if player4totalProfit >= 0 then
                    historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player4SplitHand2Coins:Hide()
    playerFrame.player4SplitHand2NormalWinCoins:Show()

    player4SessionWin = player4SessionWin + tonumber(player4SplitHand2NormalWinAmountValue)

end

function player4InsuranceWin(message)

    player4InsuranceBetText = playerFrame.player4InsuranceBetAmount:GetText()

    if player4InsuranceBetText and player4InsuranceBetText ~= "" then
        player4InsuranceBetAmountValue = tonumber(string.match(player4InsuranceBetText, "%d+"))

        if player4InsuranceBetAmountValue then
            player4InsuranceWinAmountValue = player4InsuranceBetAmountValue * 3

            player4InsuranceProfitValue = player4InsuranceWinAmountValue - player4InsuranceBetAmountValue


            if playerName == unitName4 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player4totalWin = player4totalWin + tonumber(player4InsuranceProfitValue)
                    bankingInfo.totalWon = player4totalWin
                    player4totalProfit = player4totalProfit + tonumber(player4InsuranceProfitValue)
                    bankingInfo.totalProfit = player4totalProfit
                    player4TotalBankrollAmount = player4TotalBankrollAmount + tonumber(player4InsuranceWinAmountValue)
                    bankingInfo.bankrollTable = player4TotalBankrollAmount
                end
            end
        
            if player4totalProfit >= 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
        
            historyFrame.player4totalWonAmount:SetText(player4totalWin .. " G")
            historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")
            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")

            player4SessionWin = player4SessionWin + tonumber(player4InsuranceWinAmountValue)

        end
    end
end

function player4InsuranceLoss(message)

    player4InsuranceBetText = playerFrame.player4InsuranceBetAmount:GetText()

    if player4InsuranceBetText and player4InsuranceBetText ~= "" then
        player4InsuranceBetAmountValue = tonumber(string.match(player4InsuranceBetText, "%d+"))

        if player4InsuranceBetAmountValue then

            if playerName == unitName4 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player4totalLoss = player4totalLoss + tonumber(player4InsuranceBetAmountValue)
                    bankingInfo.totalLost = player4totalLoss
                    player4totalProfit = player4totalProfit - tonumber(player4InsuranceBetAmountValue)
                    bankingInfo.totalProfit = player4totalProfit
                end
            end
    
            if player4totalProfit >= 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
    
            historyFrame.player4totalLostAmount:SetText(player4totalLoss .. " G")
            historyFrame.player4ProfitAmount:SetText(player4totalProfit .. " G")

        end
    end
end

function player4SessionWinAnnouncement()
    if playerName == unitName4 then
        if player4SessionWinCalled == false then
            if player4SessionWin >= 50 then
                chatFrame = SELECTED_DOCK_FRAME
                ChatFrame_OpenChat("/me", chatFrame)
                
                editBox = _G[chatFrame:GetName().."EditBox"]
                editBox:SetText("")
                editBox:Insert("/me has won " .. player4SessionWin .. "g from a hand of Blackjack.")
                
                ChatEdit_SendText(editBox)
                ChatEdit_DeactivateChat(editBox)

                UpdateWinningsDisplay(playerFrame.player4WinningsUpdate, player4SessionWin)
                player4resetRaidChannel()
                
            else
                print("")
            end

            player4SessionWinCalled = true
        end
    end
end

















-- >>> PLAYER 5 <<<
-- >>> PLAYER 5 <<<
-- >>> PLAYER 5 <<<

playerFrame.player5CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", -385, 368)
playerFrame.player5CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 28, "OUTLINE") -- Adjust the font and size as needed
playerFrame.player5CardTotalText:SetText("")

playerFrame.player5SplitHand1CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5SplitHand1CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", -370, 355)
playerFrame.player5SplitHand1CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
playerFrame.player5SplitHand1CardTotalText:SetText("")

playerFrame.player5SplitHand2CardTotalText = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5SplitHand2CardTotalText:SetPoint("BOTTOM", playerFrame, "BOTTOM", -400, 395)
playerFrame.player5SplitHand2CardTotalText:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
playerFrame.player5SplitHand2CardTotalText:SetText("")

-- Buttons for Player 5
-- Hit
playerFrame.player5HitButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5HitButton:SetPoint("BOTTOM", playerFrame, -472, 275)
playerFrame.player5HitButton:SetSize(65, 30)
playerFrame.player5HitButton:SetText("Hit")
playerFrame.player5HitButton:Disable()
playerFrame.player5HitButton:Hide()
-- Stand
playerFrame.player5StandButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5StandButton:SetPoint("BOTTOM", playerFrame, -406, 275)
playerFrame.player5StandButton:SetSize(65, 30)
playerFrame.player5StandButton:SetText("Stand")
playerFrame.player5StandButton:Disable()
playerFrame.player5StandButton:Hide()
-- Double
playerFrame.player5DoubleButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5DoubleButton:SetPoint("BOTTOM", playerFrame, -472, 245)
playerFrame.player5DoubleButton:SetSize(65, 30)
playerFrame.player5DoubleButton:SetText("Double")
playerFrame.player5DoubleButton:Disable()
playerFrame.player5DoubleButton:Hide()
-- Split
playerFrame.player5SplitButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5SplitButton:SetPoint("BOTTOM", playerFrame, -406, 245)
playerFrame.player5SplitButton:SetSize(65, 30)
playerFrame.player5SplitButton:SetText("Split")
playerFrame.player5SplitButton:Disable()
playerFrame.player5SplitButton:Hide()
-- Insurance Yes
playerFrame.player5InsuranceYesButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5InsuranceYesButton:SetPoint("BOTTOM", playerFrame, -505, 215)
playerFrame.player5InsuranceYesButton:SetSize(55, 30)
playerFrame.player5InsuranceYesButton:SetText("Yes")
playerFrame.player5InsuranceYesButton:Disable()
playerFrame.player5InsuranceYesButton:Hide()
-- Insurance No
playerFrame.player5InsuranceNoButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5InsuranceNoButton:SetPoint("BOTTOM", playerFrame, -378, 215)
playerFrame.player5InsuranceNoButton:SetSize(55, 30)
playerFrame.player5InsuranceNoButton:SetText("No")
playerFrame.player5InsuranceNoButton:Disable()
playerFrame.player5InsuranceNoButton:Hide()
-- Deal Now
playerFrame.player5DealNowButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5DealNowButton:SetPoint("BOTTOM", playerFrame, -439, 215)
playerFrame.player5DealNowButton:SetSize(85, 30)
playerFrame.player5DealNowButton:SetText("Deal Now")
playerFrame.player5DealNowButton:Disable()
playerFrame.player5DealNowButton:Hide()
-- Hit (Split H1)
playerFrame.player5HitButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5HitButtonSplitH1:SetPoint("BOTTOM", playerFrame, -406, 275)
playerFrame.player5HitButtonSplitH1:SetSize(65, 30)
playerFrame.player5HitButtonSplitH1:SetText("Hit")
playerFrame.player5HitButtonSplitH1:Disable()
playerFrame.player5HitButtonSplitH1:Hide()
-- Stand (Split H1)
playerFrame.player5StandButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5StandButtonSplitH1:SetPoint("BOTTOM", playerFrame, -406, 245)
playerFrame.player5StandButtonSplitH1:SetSize(65, 30)
playerFrame.player5StandButtonSplitH1:SetText("Stand")
playerFrame.player5StandButtonSplitH1:Disable()
playerFrame.player5StandButtonSplitH1:Hide()
-- Double (Split H1)
playerFrame.player5DoubleButtonSplitH1 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5DoubleButtonSplitH1:SetPoint("BOTTOM", playerFrame, -406, 215)
playerFrame.player5DoubleButtonSplitH1:SetSize(65, 30)
playerFrame.player5DoubleButtonSplitH1:SetText("Double")
playerFrame.player5DoubleButtonSplitH1:Disable()
playerFrame.player5DoubleButtonSplitH1:Hide()
-- Hit (Split H2)
playerFrame.player5HitButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5HitButtonSplitH2:SetPoint("BOTTOM", playerFrame, -472, 275)
playerFrame.player5HitButtonSplitH2:SetSize(65, 30)
playerFrame.player5HitButtonSplitH2:SetText("Hit")
playerFrame.player5HitButtonSplitH2:Disable()
playerFrame.player5HitButtonSplitH2:Hide()
-- Stand (Split H2)
playerFrame.player5StandButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5StandButtonSplitH2:SetPoint("BOTTOM", playerFrame, -472, 245)
playerFrame.player5StandButtonSplitH2:SetSize(65, 30)
playerFrame.player5StandButtonSplitH2:SetText("Stand")
playerFrame.player5StandButtonSplitH2:Disable()
playerFrame.player5StandButtonSplitH2:Hide()
-- Double (Split H2)
playerFrame.player5DoubleButtonSplitH2 = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
playerFrame.player5DoubleButtonSplitH2:SetPoint("BOTTOM", playerFrame, -472, 215)
playerFrame.player5DoubleButtonSplitH2:SetSize(65, 30)
playerFrame.player5DoubleButtonSplitH2:SetText("Double")
playerFrame.player5DoubleButtonSplitH2:Disable()
playerFrame.player5DoubleButtonSplitH2:Hide()
-- Main Bet Confirm
player5ConfirmMainBetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player5ConfirmMainBetButton:SetPoint("BOTTOM", playerFrame, -406, 334)
player5ConfirmMainBetButton:SetSize(65, 30)
player5ConfirmMainBetButton:SetText("Bet")
player5ConfirmMainBetButton:Hide()
-- Perfect Pairs Confirm
player5ConfirmPPBetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player5ConfirmPPBetButton:SetPoint("BOTTOM", playerFrame, -375, 468)
player5ConfirmPPBetButton:SetSize(43, 25)
player5ConfirmPPBetButton:SetText("Bet")
player5ConfirmPPBetButton:Hide()
-- 21+3 Confirm
player5Confirm213BetButton = CreateFrame("Button", nil, playerFrame, "GameMenuButtonTemplate")
player5Confirm213BetButton:SetPoint("BOTTOM", playerFrame, -305, 335)
player5Confirm213BetButton:SetSize(43, 25)
player5Confirm213BetButton:SetText("Bet")
player5Confirm213BetButton:Hide()

-- Wagers for Player 5
-- Main Bet
player5MainBetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player5MainBetEditBox:SetSize(55, 30)
player5MainBetEditBox:SetPoint("BOTTOM", playerFrame, -468, 334)
player5MainBetEditBox:SetAutoFocus(false)
player5MainBetEditBox:SetNumeric(true)
player5MainBetEditBox:Hide()
-- Split Hand 1
player5SplitH1EditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player5SplitH1EditBox:SetSize(55, 30)
player5SplitH1EditBox:SetPoint("BOTTOM", playerFrame, -403, 334)
player5SplitH1EditBox:SetAutoFocus(false)
player5SplitH1EditBox:SetNumeric(true)
player5SplitH1EditBox:ClearFocus()
player5SplitH1EditBox:Disable()
player5SplitH1EditBox:Hide()
-- Split Hand 2
player5SplitH2EditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player5SplitH2EditBox:SetSize(55, 30)
player5SplitH2EditBox:SetPoint("BOTTOM", playerFrame, -468, 334)
player5SplitH2EditBox:SetAutoFocus(false)
player5SplitH2EditBox:SetNumeric(true)
player5SplitH2EditBox:ClearFocus()
player5SplitH2EditBox:Disable()
player5SplitH2EditBox:Hide()
-- Perfect Pairs
player5PPBetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player5PPBetEditBox:SetSize(35, 30)
player5PPBetEditBox:SetPoint("BOTTOM", playerFrame, -373, 488)
player5PPBetEditBox:SetAutoFocus(false)
player5PPBetEditBox:SetNumeric(true)
player5PPBetEditBox:Hide()
-- 21+3
player5213BetEditBox = CreateFrame("EditBox", nil, playerFrame, "InputBoxTemplate")
player5213BetEditBox:SetSize(35, 30)
player5213BetEditBox:SetPoint("BOTTOM", playerFrame, -303, 355)
player5213BetEditBox:SetAutoFocus(false)
player5213BetEditBox:SetNumeric(true)
player5213BetEditBox:Hide()

-- Labels for Player 5
-- Main Bet
playerFrame.player5MainBetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5MainBetTitle:SetPoint("BOTTOM", playerFrame, -468, 362)
playerFrame.player5MainBetTitle:SetJustifyH("CENTER")
playerFrame.player5MainBetTitle:SetText("Main Bet")
playerFrame.player5MainBetTitle:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player5MainBetTitle:Hide()
-- Split Hand 1
playerFrame.player5SplitH1Title = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5SplitH1Title:SetPoint("BOTTOM", playerFrame, -403, 362)
playerFrame.player5SplitH1Title:SetJustifyH("CENTER")
playerFrame.player5SplitH1Title:SetText("Hand 1")
playerFrame.player5SplitH1Title:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player5SplitH1Title:Hide()
-- Split Hand 2
playerFrame.player5SplitH2Title = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5SplitH2Title:SetPoint("BOTTOM", playerFrame, -468, 362)
playerFrame.player5SplitH2Title:SetJustifyH("CENTER")
playerFrame.player5SplitH2Title:SetText("Hand 2")
playerFrame.player5SplitH2Title:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player5SplitH2Title:Hide()
-- Main Bet Amount
player5MainBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5MainBetAmount:SetPoint("CENTER", playerFrame, -330, 97)
player5MainBetAmount:SetJustifyH("CENTER")
player5MainBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Split Hand 1 Amount
player5SplitH1BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5SplitH1BetAmount:SetPoint("CENTER", playerFrame, -312, 103)
player5SplitH1BetAmount:SetJustifyH("CENTER")
player5SplitH1BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Split Hand 2 Amount
player5SplitH2BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5SplitH2BetAmount:SetPoint("CENTER", playerFrame, -347, 103)
player5SplitH2BetAmount:SetJustifyH("CENTER")
player5SplitH2BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Perfect Pairs
playerFrame.player5PPBetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5PPBetTitle:SetPoint("BOTTOM", playerFrame, -408, 483)
playerFrame.player5PPBetTitle:SetJustifyH("CENTER")
playerFrame.player5PPBetTitle:SetText("PP")
playerFrame.player5PPBetTitle:SetFont("Fonts\\FRIZQT__.TTF", 15, "OUTLINE")
playerFrame.player5PPBetTitle:Hide()
-- Perfect Pairs Amount
player5PPBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5PPBetAmount:SetPoint("CENTER", playerFrame, -328, 154)
player5PPBetAmount:SetJustifyH("CENTER")
player5PPBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- 21+3
playerFrame.player5213BetTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5213BetTitle:SetPoint("BOTTOM", playerFrame, -261, 351)
playerFrame.player5213BetTitle:SetJustifyH("CENTER")
playerFrame.player5213BetTitle:SetText("21+3")
playerFrame.player5213BetTitle:SetFont("Fonts\\FRIZQT__.TTF", 15, "OUTLINE")
playerFrame.player5213BetTitle:Hide()
-- 21+3 Amount
player5213BetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5213BetAmount:SetPoint("CENTER", playerFrame, -263, 56)
player5213BetAmount:SetJustifyH("CENTER")
player5213BetAmount:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
-- Insurance Amount
playerFrame.player5InsuranceBetAmount = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5InsuranceBetAmount:SetPoint("CENTER", playerFrame, -332, -110)
playerFrame.player5InsuranceBetAmount:SetJustifyH("CENTER")
playerFrame.player5InsuranceBetAmount:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
-- Player Name
playerFrame.player5Name = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5Name:SetPoint("BOTTOM", playerFrame, -439, 310)
playerFrame.player5Name:SetText("Seat Empty")
playerFrame.player5Name:SetFont("Fonts\\FRIZQT__.TTF", 22, "OUTLINE")
-- Insurance
playerFrame.player5InsuranceTitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5InsuranceTitle:SetPoint("BOTTOM", playerFrame, -439, 228)
playerFrame.player5InsuranceTitle:SetText("Insurance")
playerFrame.player5InsuranceTitle:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
playerFrame.player5InsuranceTitle:Hide()
-- Insurance (if available)
playerFrame.player5InsuranceSubtitle = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5InsuranceSubtitle:SetPoint("BOTTOM", playerFrame, -439, 218)
playerFrame.player5InsuranceSubtitle:SetText("(if available)")
playerFrame.player5InsuranceSubtitle:SetFont("Fonts\\FRIZQT__.TTF", 8, "OUTLINE")
playerFrame.player5InsuranceSubtitle:Hide()
-- Session Win Update
playerFrame.player5WinningsUpdate = playerFrame:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
playerFrame.player5WinningsUpdate:SetPoint("BOTTOMLEFT", playerFrame, 270, 30) 
playerFrame.player5WinningsUpdate:SetText("")
playerFrame.player5WinningsUpdate:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
playerFrame.player5WinningsUpdate:SetTextColor(0.118, 0.839, 0.412)

-- Images for Player 5
-- Turn Arrow
playerFrame.player5TurnArrow = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5TurnArrow:SetSize(128, 128)
playerFrame.player5TurnArrow:SetPoint("CENTER", playerFrame, -330, -20)
playerFrame.player5TurnArrow:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\TurnArrow.tga")
playerFrame.player5TurnArrow:SetBlendMode("BLEND")
playerFrame.player5TurnArrow:SetDrawLayer("OVERLAY")
playerFrame.player5TurnArrow:Hide()
-- Main Bet
playerFrame.player5MainBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5MainBetCoins:SetSize(128, 128)
playerFrame.player5MainBetCoins:SetPoint("CENTER", playerFrame, -308, 68)
playerFrame.player5MainBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player5MainBetCoins:SetBlendMode("BLEND")
playerFrame.player5MainBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player5MainBetCoins:Hide()
-- Win
playerFrame.player5NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5NormalWinCoins:SetSize(128, 128)
playerFrame.player5NormalWinCoins:SetPoint("CENTER", playerFrame, -308, 68)
playerFrame.player5NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player5NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player5NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player5NormalWinCoins:Hide()
-- Split Hand 2 Bet
playerFrame.player5SplitHand2Coins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5SplitHand2Coins:SetSize(128, 128)
playerFrame.player5SplitHand2Coins:SetPoint("CENTER", playerFrame, -322, 83)
playerFrame.player5SplitHand2Coins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player5SplitHand2Coins:SetBlendMode("BLEND")
playerFrame.player5SplitHand2Coins:SetDrawLayer("OVERLAY")
playerFrame.player5SplitHand2Coins:Hide()
-- Split Double Hand 2 Bet
playerFrame.player5SplitHand2DoubleCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5SplitHand2DoubleCoins:SetSize(128, 128)
playerFrame.player5SplitHand2DoubleCoins:SetPoint("CENTER", playerFrame, -322, 83)
playerFrame.player5SplitHand2DoubleCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player5SplitHand2DoubleCoins:SetBlendMode("BLEND")
playerFrame.player5SplitHand2DoubleCoins:SetDrawLayer("OVERLAY")
playerFrame.player5SplitHand2DoubleCoins:Hide()
-- Split Win Hand 2
playerFrame.player5SplitHand2NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5SplitHand2NormalWinCoins:SetSize(128, 128)
playerFrame.player5SplitHand2NormalWinCoins:SetPoint("CENTER", playerFrame, -322, 83)
playerFrame.player5SplitHand2NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player5SplitHand2NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player5SplitHand2NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player5SplitHand2NormalWinCoins:Hide()
-- Split Hand 1 Bet
playerFrame.player5SplitHand1Coins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5SplitHand1Coins:SetSize(128, 128)
playerFrame.player5SplitHand1Coins:SetPoint("CENTER", playerFrame, -295, 58)
playerFrame.player5SplitHand1Coins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player5SplitHand1Coins:SetBlendMode("BLEND")
playerFrame.player5SplitHand1Coins:SetDrawLayer("OVERLAY")
playerFrame.player5SplitHand1Coins:Hide()
-- Split Double Hand 1 Bet
playerFrame.player5SplitHand1DoubleCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5SplitHand1DoubleCoins:SetSize(128, 128)
playerFrame.player5SplitHand1DoubleCoins:SetPoint("CENTER", playerFrame, -295, 58)
playerFrame.player5SplitHand1DoubleCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player5SplitHand1DoubleCoins:SetBlendMode("BLEND")
playerFrame.player5SplitHand1DoubleCoins:SetDrawLayer("OVERLAY")
playerFrame.player5SplitHand1DoubleCoins:Hide()
-- Split Win Hand 1
playerFrame.player5SplitHand1NormalWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5SplitHand1NormalWinCoins:SetSize(128, 128)
playerFrame.player5SplitHand1NormalWinCoins:SetPoint("CENTER", playerFrame, -295, 58)
playerFrame.player5SplitHand1NormalWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player5SplitHand1NormalWinCoins:SetBlendMode("BLEND")
playerFrame.player5SplitHand1NormalWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player5SplitHand1NormalWinCoins:Hide()
-- Blackjack Win
playerFrame.player5BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5BJWinCoins:SetSize(128, 128)
playerFrame.player5BJWinCoins:SetPoint("CENTER", playerFrame, -308, 68)
playerFrame.player5BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player5BJWinCoins:SetBlendMode("BLEND")
playerFrame.player5BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player5BJWinCoins:Hide()
-- Split BJ Win Hand 2
playerFrame.player5SplitHand2BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5SplitHand2BJWinCoins:SetSize(128, 128)
playerFrame.player5SplitHand2BJWinCoins:SetPoint("CENTER", playerFrame, -322, 83)
playerFrame.player5SplitHand2BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player5SplitHand2BJWinCoins:SetBlendMode("BLEND")
playerFrame.player5SplitHand2BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player5SplitHand2BJWinCoins:Hide()
-- Split BJ Win Hand 1
playerFrame.player5SplitHand1BJWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5SplitHand1BJWinCoins:SetSize(128, 128)
playerFrame.player5SplitHand1BJWinCoins:SetPoint("CENTER", playerFrame, -295, 58)
playerFrame.player5SplitHand1BJWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBJWin.tga")
playerFrame.player5SplitHand1BJWinCoins:SetBlendMode("BLEND")
playerFrame.player5SplitHand1BJWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player5SplitHand1BJWinCoins:Hide()
-- Double Bet
playerFrame.player5DoubleBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5DoubleBetCoins:SetSize(128, 128)
playerFrame.player5DoubleBetCoins:SetPoint("CENTER", playerFrame, -308, 68)
playerFrame.player5DoubleBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsWin.tga")
playerFrame.player5DoubleBetCoins:SetBlendMode("BLEND")
playerFrame.player5DoubleBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player5DoubleBetCoins:Hide()
-- PP Bet
playerFrame.player5PPBetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5PPBetCoins:SetSize(128, 128)
playerFrame.player5PPBetCoins:SetPoint("CENTER", playerFrame, -323, 136)
playerFrame.player5PPBetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsHalfBet.tga")
playerFrame.player5PPBetCoins:SetBlendMode("BLEND")
playerFrame.player5PPBetCoins:SetDrawLayer("OVERLAY")
playerFrame.player5PPBetCoins:Hide()
-- 21+3 Bet
playerFrame.player5213BetCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5213BetCoins:SetSize(128, 128)
playerFrame.player5213BetCoins:SetPoint("CENTER", playerFrame, -258, 36)
playerFrame.player5213BetCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsHalfBet.tga")
playerFrame.player5213BetCoins:SetBlendMode("BLEND")
playerFrame.player5213BetCoins:SetDrawLayer("OVERLAY")
playerFrame.player5213BetCoins:Hide()
-- PP Win
playerFrame.player5PPWinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5PPWinCoins:SetSize(128, 128)
playerFrame.player5PPWinCoins:SetPoint("CENTER", playerFrame, -311, 140)
playerFrame.player5PPWinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player5PPWinCoins:SetBlendMode("BLEND")
playerFrame.player5PPWinCoins:SetDrawLayer("OVERLAY")
playerFrame.player5PPWinCoins:Hide()
-- 21+3 Win
playerFrame.player5213WinCoins = playerFrame:CreateTexture(nil, "OVERLAY")
playerFrame.player5213WinCoins:SetSize(128, 128)
playerFrame.player5213WinCoins:SetPoint("CENTER", playerFrame, -247, 41)
playerFrame.player5213WinCoins:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\CoinsBet.tga")
playerFrame.player5213WinCoins:SetBlendMode("BLEND")
playerFrame.player5213WinCoins:SetDrawLayer("OVERLAY")
playerFrame.player5213WinCoins:Hide()
-- Insurance YES for Player 5
player5InsuranceYesIcon = playerFrame:CreateTexture(nil, "OVERLAY")
player5InsuranceYesIcon:SetSize(24, 24)
player5InsuranceYesIcon:SetPoint("CENTER", playerFrame, -336, -130)
player5InsuranceYesIcon:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\insuranceYes.tga")
player5InsuranceYesIcon:SetDrawLayer("OVERLAY")
player5InsuranceYesIcon:Hide()
-- Insurance NO for Player 5
player5InsuranceNoIcon = playerFrame:CreateTexture(nil, "OVERLAY")
player5InsuranceNoIcon:SetSize(24, 24)
player5InsuranceNoIcon:SetPoint("CENTER", playerFrame, -336, -130)
player5InsuranceNoIcon:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\insuranceNo.tga")
player5InsuranceNoIcon:SetDrawLayer("OVERLAY")
player5InsuranceNoIcon:Hide()

-- BJ Win Coins
function player5PlaceCoinsBJWin(message)
    playerFrame.player5MainBetCoins:Hide()
    playerFrame.player5BJWinCoins:Show()
end

-- Regular Win Coins
function player5PlaceCoinsRegularWin(message)
    playerFrame.player5MainBetCoins:Hide()
    playerFrame.player5DoubleBetCoins:Show()
end

-- Main Bet Coins
function player5PlaceCoinsMainBet(message)
    playerFrame.player5MainBetCoins:Show()
end

-- Double Bet Coins
function player5PlaceCoinsDoubleBet(message)
    playerFrame.player5MainBetCoins:Hide()
    playerFrame.player5DoubleBetCoins:Show()
end

-- Function to handle Player 5 Main Bet Text
function player5PlaceTextMainBet(message)
    player5HistoryMainBet = string.match(message, "(%d+)G")

        if player5HistoryMainBet then
            player5MainBetAmount:SetText(player5HistoryMainBet .. " G")
            player5MainBetAmount:Show()

            if playerName == unitName5 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName5]
                    player5totalBetAmount = player5totalBetAmount + tonumber(player5HistoryMainBet)
                    bankingInfo.totalWagered = player5totalBetAmount
                end
            end

            historyFrame.player5totalWageredAmount:SetText(player5totalBetAmount .. " G")

        else
    end
end

-- Player 5 Split Hand Bet Text
function player5SplitHand1BetText(Amount)
    player5MainBetAmount:Hide()
    player5MainBetAmount:SetText("")
    player5SplitH1BetAmount:SetText(Amount .. " G")
    player5SplitH1BetAmount:Show()
    player5SplitH2BetAmount:SetText(Amount .. " G")
    player5SplitH2BetAmount:Show()
end

-- Player 5 Split Bet Image
function player5PlaceSplitBet(message)
    playerFrame.player5MainBetCoins:Hide()
    playerFrame.player5SplitHand1Coins:Show()
    playerFrame.player5SplitHand2Coins:Show()
end

-- Player 5 Place Initial Card Images
function player5PlaceSplitCards(message)

    -- Players: 5
    if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
        drawnCards[1]:Hide()
        drawnCards[3]:Hide()
        player5cardName1 = dealtCards[1]
        player5cardName2 = dealtCards[3]
        turn = 8 -- Player 5: 2nd Card (Split H1)

    -- Players: 1, 5
    elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
        drawnCards[2]:Hide()
        drawnCards[5]:Hide()
        player5cardName1 = dealtCards[2]
        player5cardName2 = dealtCards[5]
        turn = 30 -- Player 5: 2nd Card (Split H1)
    -- Players: 2, 5
    elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
        drawnCards[2]:Hide()
        drawnCards[5]:Hide()
        player5cardName1 = dealtCards[2]
        player5cardName2 = dealtCards[5]
        turn = 30 -- Player 5: 2nd Card (Split H1)
    -- Players: 3, 5
    elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
        drawnCards[2]:Hide()
        drawnCards[5]:Hide()
        player5cardName1 = dealtCards[2]
        player5cardName2 = dealtCards[5]
        turn = 30 -- Player 5: 2nd Card (Split H1)
    -- Players: 4, 5
    elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
        drawnCards[2]:Hide()
        drawnCards[5]:Hide()
        player5cardName1 = dealtCards[2]
        player5cardName2 = dealtCards[5]
        turn = 30 -- Player 5: 2nd Card (Split H1)

    -- Players: 1, 2, 5
    elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
        drawnCards[3]:Hide()
        drawnCards[7]:Hide()
        player5cardName1 = dealtCards[3]
        player5cardName2 = dealtCards[7]
        turn = 52 -- Player 5: 2nd Card (Split H1)
    -- Players: 1, 3, 5
    elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
        drawnCards[3]:Hide()
        drawnCards[7]:Hide()
        player5cardName1 = dealtCards[3]
        player5cardName2 = dealtCards[7]
        turn = 52 -- Player 5: 2nd Card (Split H1)
    -- Players: 1, 4, 5
    elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
        drawnCards[3]:Hide()
        drawnCards[7]:Hide()
        player5cardName1 = dealtCards[3]
        player5cardName2 = dealtCards[7]
        turn = 52 -- Player 5: 2nd Card (Split H1)
    -- Players: 2, 3, 5
    elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
        drawnCards[3]:Hide()
        drawnCards[7]:Hide()
        player5cardName1 = dealtCards[3]
        player5cardName2 = dealtCards[7]
        turn = 52 -- Player 5: 2nd Card (Split H1)
    -- Players: 2, 4, 5
    elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
        drawnCards[3]:Hide()
        drawnCards[7]:Hide()
        player5cardName1 = dealtCards[3]
        player5cardName2 = dealtCards[7]
        turn = 52 -- Player 5: 2nd Card (Split H1)
    -- Players: 3, 4, 5
    elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
        drawnCards[3]:Hide()
        drawnCards[7]:Hide()
        player5cardName1 = dealtCards[3]
        player5cardName2 = dealtCards[7]
        turn = 52 -- Player 5: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 5
    elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
        drawnCards[4]:Hide()
        drawnCards[9]:Hide()
        player5cardName1 = dealtCards[4]
        player5cardName2 = dealtCards[9]
        turn = 74 -- Player 5: 2nd Card (Split H1)
    -- Players: 1, 2, 4, 5
    elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
        drawnCards[4]:Hide()
        drawnCards[9]:Hide()
        player5cardName1 = dealtCards[4]
        player5cardName2 = dealtCards[9]
        turn = 74 -- Player 5: 2nd Card (Split H1)
    -- Players: 1, 3, 4, 5
    elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
        drawnCards[4]:Hide()
        drawnCards[9]:Hide()
        player5cardName1 = dealtCards[4]
        player5cardName2 = dealtCards[9]
        turn = 74 -- Player 5: 2nd Card (Split H1)
    -- Players: 2, 3, 4, 5
    elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
        drawnCards[4]:Hide()
        drawnCards[9]:Hide()
        player5cardName1 = dealtCards[4]
        player5cardName2 = dealtCards[9]
        turn = 74 -- Player 5: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4, 5
    elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
        drawnCards[5]:Hide()
        drawnCards[11]:Hide()
        player5cardName1 = dealtCards[5]
        player5cardName2 = dealtCards[11]
        turn = 96 -- Player 5: 2nd Card (Split H1)
    end

    player5cardImageFile1 = nil
    player5cardImageFile2 = nil

    for filename, cardDescription in pairs(cardNames) do
        if cardDescription == player5cardName1 then
            player5cardImageFile1 = filename
            break
        end
    end

    for filename, cardDescription in pairs(cardNames) do
        if cardDescription == player5cardName2 then
            player5cardImageFile2 = filename
            break
        end
    end

    player5NewCardImage1 = CreateFrame("Frame", nil, playerFrame)
    player5NewCardImage1:SetSize(32, 64)
    player5NewCardImage1:SetPoint("BOTTOM", playerFrame, -253, 435)
    player5NewCardImage1.texture = player5NewCardImage1:CreateTexture()
    player5NewCardImage1.texture:SetAllPoints()
    player5NewCardImage1.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5cardImageFile1)
    player5NewCardImage1:Show()

    player5NewCardImage2 = CreateFrame("Frame", nil, playerFrame)
    player5NewCardImage2:SetSize(32, 64)
    player5NewCardImage2:SetPoint("BOTTOM", playerFrame, -290, 454)
    player5NewCardImage2.texture = player5NewCardImage2:CreateTexture()
    player5NewCardImage2.texture:SetAllPoints()
    player5NewCardImage2.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5cardImageFile2)
    player5NewCardImage2:Show()

end

-- Player 5 Split Function
function player5HandleSplit(message)
    player5PlaceSplitBet()
    player5MainBetAmountValue = tonumber(string.match(player5MainBetAmount:GetText(), "%d+"))
    if player5MainBetAmountValue then
        player5SplitHand1BetText(player5MainBetAmountValue)
    end 

    player5PlaceSplitCards()

    -- A,A
    if playerFrame.player5CardTotalText:GetText() == "2 or 12" then
        playerFrame.player5SplitHand1CardTotalText:SetText("1 or 11")
        playerFrame.player5SplitHand1CardTotalText:Show()
        playerFrame.player5SplitHand2CardTotalText:SetText("1 or 11")
        playerFrame.player5SplitHand2CardTotalText:Show()
    -- 2,2
    elseif playerFrame.player5CardTotalText:GetText() == "4" then
        playerFrame.player5SplitHand1CardTotalText:SetText("2")
        playerFrame.player5SplitHand1CardTotalText:Show()
        playerFrame.player5SplitHand2CardTotalText:SetText("2")
        playerFrame.player5SplitHand2CardTotalText:Show()
    -- 3,3
    elseif playerFrame.player5CardTotalText:GetText() == "6" then
        playerFrame.player5SplitHand1CardTotalText:SetText("3")
        playerFrame.player5SplitHand1CardTotalText:Show()
        playerFrame.player5SplitHand2CardTotalText:SetText("3")
        playerFrame.player5SplitHand2CardTotalText:Show()
    -- 4,4
    elseif playerFrame.player5CardTotalText:GetText() == "8" then
        playerFrame.player5SplitHand1CardTotalText:SetText("4")
        playerFrame.player5SplitHand1CardTotalText:Show()
        playerFrame.player5SplitHand2CardTotalText:SetText("4")
        playerFrame.player5SplitHand2CardTotalText:Show()
    -- 5,5
    elseif playerFrame.player5CardTotalText:GetText() == "10" then
        playerFrame.player5SplitHand1CardTotalText:SetText("5")
        playerFrame.player5SplitHand1CardTotalText:Show()
        playerFrame.player5SplitHand2CardTotalText:SetText("5")
        playerFrame.player5SplitHand2CardTotalText:Show()
    -- 6,6
    elseif playerFrame.player5CardTotalText:GetText() == "12" then
        playerFrame.player5SplitHand1CardTotalText:SetText("6")
        playerFrame.player5SplitHand1CardTotalText:Show()
        playerFrame.player5SplitHand2CardTotalText:SetText("6")
        playerFrame.player5SplitHand2CardTotalText:Show()
    -- 7,7
    elseif playerFrame.player5CardTotalText:GetText() == "14" then
        playerFrame.player5SplitHand1CardTotalText:SetText("7")
        playerFrame.player5SplitHand1CardTotalText:Show()
        playerFrame.player5SplitHand2CardTotalText:SetText("7")
        playerFrame.player5SplitHand2CardTotalText:Show()
    -- 8,8
    elseif playerFrame.player5CardTotalText:GetText() == "16" then
        playerFrame.player5SplitHand1CardTotalText:SetText("8")
        playerFrame.player5SplitHand1CardTotalText:Show()
        playerFrame.player5SplitHand2CardTotalText:SetText("8")
        playerFrame.player5SplitHand2CardTotalText:Show()
    -- 9,9
    elseif playerFrame.player5CardTotalText:GetText() == "18" then
        playerFrame.player5SplitHand1CardTotalText:SetText("9")
        playerFrame.player5SplitHand1CardTotalText:Show()
        playerFrame.player5SplitHand2CardTotalText:SetText("9")
        playerFrame.player5SplitHand2CardTotalText:Show()
    -- 10,10
    elseif playerFrame.player5CardTotalText:GetText() == "20" then
        playerFrame.player5SplitHand1CardTotalText:SetText("10")
        playerFrame.player5SplitHand1CardTotalText:Show()
        playerFrame.player5SplitHand2CardTotalText:SetText("10")
        playerFrame.player5SplitHand2CardTotalText:Show()
    end

    playerFrame.player5CardTotalText:SetText("")
    playerFrame.player5CardTotalText:Hide()
    
    if playerName == unitName5 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player5totalBetAmount = player5totalBetAmount + tonumber(player5MainBetAmountValue)
            bankingInfo.totalWagered = player5totalBetAmount
            player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(player5MainBetAmountValue)
            bankingInfo.bankrollTable = player5TotalBankrollAmount
        end
    end

    historyFrame.player5totalWageredAmount:SetText(player5totalBetAmount .. " G")
    bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
    cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

    player5SplitToggle = true

    if player5dealtCardsFrame:IsShown() then
        player5dealtCardsFrame:Hide()
        player5dealtCardsFrame.playerCardsButton:Hide()
        player5dealtCardsFrameSplitH1:Show()
        player5dealtCardsFrameSplitH1.playerH1CardsButton:Show()
        player5dealtCardsFrameSplitH1.playerH2CardsButton:Show()
    end

end

-- Function to handle Player 5 PP Bet Image
function player5PlaceCoinsPPBet(message)
    playerFrame.player5PPBetCoins:Show()
end

-- Function to handle Player 5 PP Bet Text
function player5PlaceTextPPBet(message)
    player5HistoryPPBet = string.match(message, "(%d+)G")

        if player5HistoryPPBet then
            player5PPBetAmount:SetText(player5HistoryPPBet .. " G")
            player5PPBetAmount:Show()

            if playerName == unitName5 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName5]
                    player5totalBetAmount = player5totalBetAmount + tonumber(player5HistoryPPBet)
                    bankingInfo.totalWagered = player5totalBetAmount
                end
            end

            historyFrame.player5totalWageredAmount:SetText(player5totalBetAmount .. " G")

        else
    end
end

-- Function to handle Player 5 21+3 Bet Image
function player5PlaceCoins213Bet(message)
    playerFrame.player5213BetCoins:Show()
end

-- Function to handle Player 5 21+3 Bet Text
function player5PlaceText213Bet(message)
    player5History213Bet = string.match(message, "(%d+)G")

        if player5History213Bet then
            player5213BetAmount:SetText(player5History213Bet .. " G")
            player5213BetAmount:Show()

            if playerName == unitName5 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[unitName5]
                    player5totalBetAmount = player5totalBetAmount + tonumber(player5History213Bet)
                    bankingInfo.totalWagered = player5totalBetAmount
                end
            end

            historyFrame.player5totalWageredAmount:SetText(player5totalBetAmount .. " G")

        else
    end
end

function player5PreloadBet()
    
    player5MainBet = tonumber(player5PreloadEditBoxMainBet:GetText()) or 0
    player5PPBet = tonumber(player5PreloadEditBoxPPBet:GetText()) or 0
    player5213Bet = tonumber(player5PreloadEditBox213Bet:GetText()) or 0

    player5TotalRebetAmount = player5MainBet + player5PPBet + player5213Bet

    player5currentBankroll = tonumber(string.match(bankrollFrame.player5TotalBankrollTableDisplay:GetText(), "%d+"))

    if player5currentBankroll - player5TotalRebetAmount < 0 then
        print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
    else
        player5Threshold = minBetMain - 1
        if player5MainBet <= player5Threshold then
            print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
        else
            if player5MainBet and player5MainBet >= minBetMain and player5MainBet <= maxBetMain then
                PlaySoundFile(soundFilePaths[33])
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P5] PIacing a " ..player5MainBet.. "G main bet.", "RAID")
                -- Disable the edit box and button
                player5PreloadEditBoxMainBet:SetFocus(false)
                player5PreloadEditBoxMainBet:ClearFocus()
                player5MainBetEditBox:SetText("")
                player5MainBetEditBox:SetText(player5MainBet)
                player5MainBetEditBox:SetFocus(false)
                player5MainBetEditBox:ClearFocus()
                player5MainBetEditBox:Disable()
                player5ConfirmMainBetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(player5MainBet)
                    bankingInfo.bankrollTable = player5TotalBankrollAmount
                end
            end

            if player5PPBet and player5PPBet >= minBetPP and player5PPBet <= maxBetPP then
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P5] PIacing a " ..player5PPBet.. "G side bet on Perfect Pairs.", "RAID")
                -- Disable the edit box and button
                player5PreloadEditBoxPPBet:SetFocus(false)
                player5PreloadEditBoxPPBet:ClearFocus()
                player5PPBetEditBox:SetText("")
                player5PPBetEditBox:SetText(player5PPBet)
                player5PPBetEditBox:SetFocus(false)
                player5PPBetEditBox:ClearFocus()
                player5PPBetEditBox:Disable()
                player5ConfirmPPBetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(player5PPBet)
                    bankingInfo.bankrollTable = player5TotalBankrollAmount
                end
            end

            if player5213Bet and player5213Bet >= minBet213 and player5213Bet <= maxBet213 then
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P5] PIacing a " ..player5213Bet.. "G side bet on 21+3.", "RAID")
                -- Disable the edit box and button
                player5PreloadEditBox213Bet:SetFocus(false)
                player5PreloadEditBox213Bet:ClearFocus()
                player5213BetEditBox:SetText("")
                player5213BetEditBox:SetText(player5213Bet)
                player5213BetEditBox:SetFocus(false)
                player5213BetEditBox:ClearFocus()
                player5213BetEditBox:Disable()
                player5Confirm213BetButton:Disable()

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(player5213Bet)
                    bankingInfo.bankrollTable = player5TotalBankrollAmount
                end
            end
            
            player5PreloadBetButton:Disable()

        end

        bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

    end

end

-- Function to handle the Player 1 Main "Bet" button click
function player5ConfirmMainBetClick()
    player5MainBet = tonumber(player5MainBetEditBox:GetText())
    player5currentBankroll = tonumber(string.match(bankrollFrame.player5TotalBankrollTableDisplay:GetText(), "%d+"))

    if player5MainBet and player5MainBet >= minBetMain and player5MainBet <= maxBetMain then
        if player5currentBankroll - player5MainBet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            -- Valid bet amount, send the message with the bet
            SendChatMessage("[P5] PIacing a " ..player5MainBet.. "G main bet.", "RAID")
            -- Disable the edit box and button
            player5MainBetEditBox:SetFocus(false)
            player5MainBetEditBox:ClearFocus()
            player5MainBetEditBox:Disable()
            player5ConfirmMainBetButton:Disable()

            player5PreloadBetButton:Disable()

            PlaySoundFile(soundFilePaths[33]) 

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(player5MainBet)
                bankingInfo.bankrollTable = player5TotalBankrollAmount
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBetMain .. "G and " .. maxBetMain .. "G.")
    end

end

-- Function to handle the Player 1 PP "Bet" button click
function player5ConfirmPPBetClick()
    player5PPBet = tonumber(player5PPBetEditBox:GetText()) -- Get the entered bet amount
    player5currentBankroll = tonumber(string.match(bankrollFrame.player5TotalBankrollTableDisplay:GetText(), "%d+"))

    if player5PPBet and player5PPBet >= minBetPP and player5PPBet <= maxBetPP then
        if player5currentBankroll - player5PPBet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            if not player5Active then
                print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
            else
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P5] PIacing a " ..player5PPBet.. "G side bet on Perfect Pairs.", "RAID")
                -- Disable the edit box and button
                player5PPBetEditBox:SetFocus(false)
                player5PPBetEditBox:ClearFocus()
                player5PPBetEditBox:Disable()
                player5ConfirmPPBetButton:Disable()

                player5PreloadBetButton:Disable()

                PlaySoundFile(soundFilePaths[33])

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(player5PPBet)
                    bankingInfo.bankrollTable = player5TotalBankrollAmount
                end

                bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
                cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

            end
        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBetPP .. "G and " .. maxBetPP .. "G.")
    end

end

-- Function to handle the Player 1 21+3 "Bet" button click
function player5Confirm213BetClick()
    player5213Bet = tonumber(player5213BetEditBox:GetText()) -- Get the entered bet amount
    player5currentBankroll = tonumber(string.match(bankrollFrame.player5TotalBankrollTableDisplay:GetText(), "%d+"))

    if player5213Bet and player5213Bet >= minBet213 and player5213Bet <= maxBet213 then
        if player5currentBankroll - player5213Bet < 0 then
            print("You do not have enough gold in your bankroll to place that bet. Please visit the Cash Desk.")
        else
            if not player5Active then
                print("You must place a minimum 'Main Bet' of " .. minBetMain .. "G before placing this side bet")
            else
                -- Valid bet amount, send the message with the bet
                SendChatMessage("[P5] PIacing a " ..player5213Bet.. "G side bet on 21+3.", "RAID")
                -- Disable the edit box and button
                player5213BetEditBox:SetFocus(false)
                player5213BetEditBox:ClearFocus()
                player5213BetEditBox:Disable()
                player5Confirm213BetButton:Disable()

                player5PreloadBetButton:Disable()

                PlaySoundFile(soundFilePaths[33])

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(player5213Bet)
                    bankingInfo.bankrollTable = player5TotalBankrollAmount
                end

                bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
                cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

            end
        end
    else
        print("Invalid bet amount. Please enter a value between " .. minBet213 .. "G and " .. maxBet213 .. "G.")
    end
 
end

-- Player 5 Main "Bet" button
player5ConfirmMainBetButton:SetScript("OnClick", player5ConfirmMainBetClick)

-- Player 5 PP "Bet" button
player5ConfirmPPBetButton:SetScript("OnClick", player5ConfirmPPBetClick)

-- Player 5 21+3 "Bet" button
player5Confirm213BetButton:SetScript("OnClick", player5Confirm213BetClick)

-- Player 5 "Bet All" Preload button
player5PreloadBetButton:SetScript("OnClick", player5PreloadBet)

function player5resetRaidChannel()
    if playerName == unitName5 then
        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/raid", chatFrame)
        
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:SetText("")
        editBox:Insert("/raid")
        
        ChatEdit_SendText(editBox)
        ChatEdit_DeactivateChat(editBox)
    else
        print("")
    end
end

player5HotstreakImage1 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage1:SetSize(36, 36)
player5HotstreakImage1:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak1.tga")
player5HotstreakImage1:SetDrawLayer("OVERLAY")
player5HotstreakImage1:Hide()

player5HotstreakImage2 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage2:SetSize(36, 36)
player5HotstreakImage2:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak2.tga")
player5HotstreakImage2:SetDrawLayer("OVERLAY")
player5HotstreakImage2:Hide()

player5HotstreakImage3 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage3:SetSize(36, 36)
player5HotstreakImage3:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak3.tga")
player5HotstreakImage3:SetDrawLayer("OVERLAY")
player5HotstreakImage3:Hide()

player5HotstreakImage4 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage4:SetSize(36, 36)
player5HotstreakImage4:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak4.tga")
player5HotstreakImage4:SetDrawLayer("OVERLAY")
player5HotstreakImage4:Hide()

player5HotstreakImage5 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage5:SetSize(36, 36)
player5HotstreakImage5:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak5.tga")
player5HotstreakImage5:SetDrawLayer("OVERLAY")
player5HotstreakImage5:Hide()

player5HotstreakImage6 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage6:SetSize(36, 36)
player5HotstreakImage6:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak6.tga")
player5HotstreakImage6:SetDrawLayer("OVERLAY")
player5HotstreakImage6:Hide()

player5HotstreakImage7 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage7:SetSize(36, 36)
player5HotstreakImage7:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak7.tga")
player5HotstreakImage7:SetDrawLayer("OVERLAY")
player5HotstreakImage7:Hide()

player5HotstreakImage8 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage8:SetSize(36, 36)
player5HotstreakImage8:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage8:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak8.tga")
player5HotstreakImage8:SetDrawLayer("OVERLAY")
player5HotstreakImage8:Hide()

player5HotstreakImage9 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage9:SetSize(36, 36)
player5HotstreakImage9:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage9:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak9.tga")
player5HotstreakImage9:SetDrawLayer("OVERLAY")
player5HotstreakImage9:Hide()

player5HotstreakImage10 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage10:SetSize(36, 36)
player5HotstreakImage10:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage10:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak10.tga")
player5HotstreakImage10:SetDrawLayer("OVERLAY")
player5HotstreakImage10:Hide()

player5HotstreakImage11 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage11:SetSize(36, 36)
player5HotstreakImage11:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage11:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak11.tga")
player5HotstreakImage11:SetDrawLayer("OVERLAY")
player5HotstreakImage11:Hide()

player5HotstreakImage12 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage12:SetSize(36, 36)
player5HotstreakImage12:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage12:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak12.tga")
player5HotstreakImage12:SetDrawLayer("OVERLAY")
player5HotstreakImage12:Hide()

player5HotstreakImage13 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage13:SetSize(36, 36)
player5HotstreakImage13:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage13:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak13.tga")
player5HotstreakImage13:SetDrawLayer("OVERLAY")
player5HotstreakImage13:Hide()

player5HotstreakImage14 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage14:SetSize(36, 36)
player5HotstreakImage14:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage14:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak14.tga")
player5HotstreakImage14:SetDrawLayer("OVERLAY")
player5HotstreakImage14:Hide()

player5HotstreakImage15 = playerFrame:CreateTexture(nil, "OVERLAY")
player5HotstreakImage15:SetSize(36, 36)
player5HotstreakImage15:SetPoint("CENTER", playerFrame, -523, -82)
player5HotstreakImage15:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\Hotstreak15.tga")
player5HotstreakImage15:SetDrawLayer("OVERLAY")
player5HotstreakImage15:Hide()

function player5HotStreakCheck()
    if player5Hotstreak == 0 then
        player5HotstreakImage1:Hide()
        player5HotstreakImage2:Hide()
        player5HotstreakImage3:Hide()
        player5HotstreakImage4:Hide()
        player5HotstreakImage5:Hide()
        player5HotstreakImage6:Hide()
        player5HotstreakImage7:Hide()
        player5HotstreakImage8:Hide()
        player5HotstreakImage9:Hide()
        player5HotstreakImage10:Hide()
        player5HotstreakImage11:Hide()
        player5HotstreakImage12:Hide()
        player5HotstreakImage13:Hide()
        player5HotstreakImage14:Hide()
        player5HotstreakImage15:Hide()
    elseif player5Hotstreak == 1 then
        player5HotstreakImage1:Show()
    elseif player5Hotstreak == 2 then
        player5HotstreakImage1:Hide()
        player5HotstreakImage2:Show()
    elseif player5Hotstreak == 3 then
        player5HotstreakImage1:Hide()
        player5HotstreakImage2:Hide()
        player5HotstreakImage3:Show()
    elseif player5Hotstreak == 4 then
        player5HotstreakImage2:Hide()
        player5HotstreakImage3:Hide()
        player5HotstreakImage4:Show()
    elseif player5Hotstreak == 5 then
        player5HotstreakImage3:Hide()
        player5HotstreakImage4:Hide()
        player5HotstreakImage5:Show()
    elseif player5Hotstreak == 6 then
        player5HotstreakImage4:Hide()
        player5HotstreakImage5:Hide()
        player5HotstreakImage6:Show()
    elseif player5Hotstreak == 7 then
        player5HotstreakImage5:Hide()
        player5HotstreakImage6:Hide()
        player5HotstreakImage7:Show()
    elseif player5Hotstreak == 8 then
        player5HotstreakImage6:Hide()
        player5HotstreakImage7:Hide()
        player5HotstreakImage8:Show()
    elseif player5Hotstreak == 9 then
        player5HotstreakImage7:Hide()
        player5HotstreakImage8:Hide()
        player5HotstreakImage9:Show()
    elseif player5Hotstreak == 10 then
        player5HotstreakImage8:Hide()
        player5HotstreakImage9:Hide()
        player5HotstreakImage10:Show()
    elseif player5Hotstreak == 11 then
        player5HotstreakImage9:Hide()
        player5HotstreakImage10:Hide()
        player5HotstreakImage11:Show()
    elseif player5Hotstreak == 12 then
        player5HotstreakImage10:Hide()
        player5HotstreakImage11:Hide()
        player5HotstreakImage12:Show()
    elseif player5Hotstreak == 13 then
        player5HotstreakImage11:Hide()
        player5HotstreakImage12:Hide()
        player5HotstreakImage13:Show()
    elseif player5Hotstreak == 14 then
        player5HotstreakImage12:Hide()
        player5HotstreakImage13:Hide()
        player5HotstreakImage14:Show()
    elseif player5Hotstreak == 15 then
        player5HotstreakImage13:Hide()
        player5HotstreakImage14:Hide()
        player5HotstreakImage15:Show()
    end
end

-- Function to handle Player 5 PP Win Image
function player5PlaceBetsPPWin(message)
    playerFrame.player5PPBetCoins:Hide()
    playerFrame.player5PPWinCoins:Show()
    player5PPBetAmount:SetPoint("CENTER", playerFrame, -328, 171)
end

-- Function to handle Player 5 21+3 Win Image
function player5PlaceBets213Win(message)
    playerFrame.player5213BetCoins:Hide()
    playerFrame.player5213WinCoins:Show()
    player5213BetAmount:SetPoint("CENTER", playerFrame, -263, 73)
end

function player5MixedPairWin(message)

    if playerName == unitName5 then
        player5PPBetAmountValue = tonumber(string.match(player5PPBetEditBox:GetText(), "%d+"))
        if player5PPBetAmountValue then
            player5NewPPAmount = player5PPBetAmountValue * mixedPairPayoutReturn
            player5PPBetAmount:SetText(player5NewPPAmount .. " G")
            player5PPBetAmount:SetTextColor(0, 1, 0)

            player5PPProfitvalue = player5NewPPAmount - player5PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player5totalWin = player5totalWin + tonumber(player5PPProfitvalue)
                    bankingInfo.totalWon = player5totalWin
                    player5totalProfit = player5totalProfit + tonumber(player5PPProfitvalue)
                    bankingInfo.totalProfit = player5totalProfit
                    player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5NewPPAmount)
                    bankingInfo.bankrollTable = player5TotalBankrollAmount
                end

            historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
            historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
            if player5totalProfit >= 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        end
    else
        player5PPBetAmountValue = tonumber(string.match(player5PPBetAmount:GetText(), "%d+"))
        if player5PPBetAmountValue then
            player5NewPPAmount = player5PPBetAmountValue * mixedPairPayoutReturn
            player5PPBetAmount:SetText(player5NewPPAmount .. " G")
            player5PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player5PlaceBetsPPWin()
    player5PPSideBetWin = true

    player5SessionWin = player5SessionWin + tonumber(player5NewPPAmount)

end

function player5ColouredPairWin(message)

    if playerName == unitName5 then
        player5PPBetAmountValue = tonumber(string.match(player5PPBetEditBox:GetText(), "%d+"))
        if player5PPBetAmountValue then
            player5NewPPAmount = player5PPBetAmountValue * colouredPairPayoutReturn
            player5PPBetAmount:SetText(player5NewPPAmount .. " G")
            player5PPBetAmount:SetTextColor(0, 1, 0)

            player5PPProfitvalue = player5NewPPAmount - player5PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player5totalWin = player5totalWin + tonumber(player5PPProfitvalue)
                    bankingInfo.totalWon = player5totalWin
                    player5totalProfit = player5totalProfit + tonumber(player5PPProfitvalue)
                    bankingInfo.totalProfit = player5totalProfit
                    player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5NewPPAmount)
                    bankingInfo.bankrollTable = player5TotalBankrollAmount
                end

            historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
            historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
            if player5totalProfit >= 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        end
    else
        player5PPBetAmountValue = tonumber(string.match(player5PPBetAmount:GetText(), "%d+"))
        if player5PPBetAmountValue then
            player5NewPPAmount = player5PPBetAmountValue * colouredPairPayoutReturn
            player5PPBetAmount:SetText(player5NewPPAmount .. " G")
            player5PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player5PlaceBetsPPWin()
    player5PPSideBetWin = true

    player5SessionWin = player5SessionWin + tonumber(player5NewPPAmount)

end

function player5PerfectPairWin(message)

    if playerName == unitName5 then
        player5PPBetAmountValue = tonumber(string.match(player5PPBetEditBox:GetText(), "%d+"))
        if player5PPBetAmountValue then
            player5NewPPAmount = player5PPBetAmountValue * perfectPairPayoutReturn
            player5PPBetAmount:SetText(player5NewPPAmount .. " G")
            player5PPBetAmount:SetTextColor(0, 1, 0)

            player5PPProfitvalue = player5NewPPAmount - player5PPBetAmountValue

                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player5totalWin = player5totalWin + tonumber(player5PPProfitvalue)
                    bankingInfo.totalWon = player5totalWin
                    player5totalProfit = player5totalProfit + tonumber(player5PPProfitvalue)
                    bankingInfo.totalProfit = player5totalProfit
                    player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5NewPPAmount)
                    bankingInfo.bankrollTable = player5TotalBankrollAmount
                end

            historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
            historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
            if player5totalProfit >= 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        end
    else
        player5PPBetAmountValue = tonumber(string.match(player5PPBetAmount:GetText(), "%d+"))
        if player5PPBetAmountValue then
            player5NewPPAmount = player5PPBetAmountValue * perfectPairPayoutReturn
            player5PPBetAmount:SetText(player5NewPPAmount .. " G")
            player5PPBetAmount:SetTextColor(0, 1, 0)
        end
    end

    player5PlaceBetsPPWin()
    player5PPSideBetWin = true

    player5SessionWin = player5SessionWin + tonumber(player5NewPPAmount)

end

function player5SuitedThreeOfAKindWin(message)

    if playerName == unitName5 then
        player5213BetAmountValue = tonumber(string.match(player5213BetEditBox:GetText(), "%d+"))
        if player5213BetAmountValue then
            player5New213Amount = player5213BetAmountValue * suitedThreeOfAKindPayoutReturn
            player5213BetAmount:SetText(player5New213Amount .. " G")
            player5213BetAmount:SetTextColor(0, 1, 0)

            player5213Profitvalue = player5New213Amount - player5213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5totalWin = player5totalWin + tonumber(player5213Profitvalue)
                bankingInfo.totalWon = player5totalWin
                player5totalProfit = player5totalProfit + tonumber(player5213Profitvalue)
                bankingInfo.totalProfit = player5totalProfit
                player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5New213Amount)
                bankingInfo.bankrollTable = player5TotalBankrollAmount
            end

            historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
            historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
            if player5totalProfit >= 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        end
    else
        player5213BetAmountValue = tonumber(string.match(player5213BetAmount:GetText(), "%d+"))
        if player5213BetAmountValue then
            player5New213Amount = player5213BetAmountValue * suitedThreeOfAKindPayoutReturn
            player5213BetAmount:SetText(player5New213Amount .. " G")
            player5213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player5PlaceBets213Win()
    player5213SideBetWin = true

    player5SessionWin = player5SessionWin + tonumber(player5New213Amount)

end

function player5StraightFlushWin(message)

    if playerName == unitName5 then
        player5213BetAmountValue = tonumber(string.match(player5213BetEditBox:GetText(), "%d+"))
        if player5213BetAmountValue then
            player5New213Amount = player5213BetAmountValue * straightFlushPayoutReturn
            player5213BetAmount:SetText(player5New213Amount .. " G")
            player5213BetAmount:SetTextColor(0, 1, 0)

            player5213Profitvalue = player5New213Amount - player5213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5totalWin = player5totalWin + tonumber(player5213Profitvalue)
                bankingInfo.totalWon = player5totalWin
                player5totalProfit = player5totalProfit + tonumber(player5213Profitvalue)
                bankingInfo.totalProfit = player5totalProfit
                player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5New213Amount)
                bankingInfo.bankrollTable = player5TotalBankrollAmount
            end

            historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
            historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
            if player5totalProfit >= 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        end
    else
        player5213BetAmountValue = tonumber(string.match(player5213BetAmount:GetText(), "%d+"))
        if player5213BetAmountValue then
            player5New213Amount = player5213BetAmountValue * straightFlushPayoutReturn
            player5213BetAmount:SetText(player5New213Amount .. " G")
            player5213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player5PlaceBets213Win()
    player5213SideBetWin = true

    player5SessionWin = player5SessionWin + tonumber(player5New213Amount)

end

function player5ThreeOfAKindWin(message)

    if playerName == unitName5 then
        player5213BetAmountValue = tonumber(string.match(player5213BetEditBox:GetText(), "%d+"))
        if player5213BetAmountValue then
            player5New213Amount = player5213BetAmountValue * threeOfAKindPayoutReturn
            player5213BetAmount:SetText(player5New213Amount .. " G")
            player5213BetAmount:SetTextColor(0, 1, 0)

            player5213Profitvalue = player5New213Amount - player5213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5totalWin = player5totalWin + tonumber(player5213Profitvalue)
                bankingInfo.totalWon = player5totalWin
                player5totalProfit = player5totalProfit + tonumber(player5213Profitvalue)
                bankingInfo.totalProfit = player5totalProfit
                player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5New213Amount)
                bankingInfo.bankrollTable = player5TotalBankrollAmount
            end

            historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
            historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
            if player5totalProfit >= 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        end
    else
        player5213BetAmountValue = tonumber(string.match(player5213BetAmount:GetText(), "%d+"))
        if player5213BetAmountValue then
            player5New213Amount = player5213BetAmountValue * threeOfAKindPayoutReturn
            player5213BetAmount:SetText(player5New213Amount .. " G")
            player5213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player5PlaceBets213Win()
    player5213SideBetWin = true

    player5SessionWin = player5SessionWin + tonumber(player5New213Amount)

end

function player5StraightWin(message)

    if playerName == unitName5 then
        player5213BetAmountValue = tonumber(string.match(player5213BetEditBox:GetText(), "%d+"))
        if player5213BetAmountValue then
            player5New213Amount = player5213BetAmountValue * straightPayoutReturn
            player5213BetAmount:SetText(player5New213Amount .. " G")
            player5213BetAmount:SetTextColor(0, 1, 0)

            player5213Profitvalue = player5New213Amount - player5213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5totalWin = player5totalWin + tonumber(player5213Profitvalue)
                bankingInfo.totalWon = player5totalWin
                player5totalProfit = player5totalProfit + tonumber(player5213Profitvalue)
                bankingInfo.totalProfit = player5totalProfit
                player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5New213Amount)
                bankingInfo.bankrollTable = player5TotalBankrollAmount
            end

            historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
            historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
            if player5totalProfit >= 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        end
    else
        player5213BetAmountValue = tonumber(string.match(player5213BetAmount:GetText(), "%d+"))
        if player5213BetAmountValue then
            player5New213Amount = player5213BetAmountValue * straightPayoutReturn
            player5213BetAmount:SetText(player5New213Amount .. " G")
            player5213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player5PlaceBets213Win()
    player5213SideBetWin = true

    player5SessionWin = player5SessionWin + tonumber(player5New213Amount)

end

function player5FlushWin(message)

    if playerName == unitName5 then
        player5213BetAmountValue = tonumber(string.match(player5213BetEditBox:GetText(), "%d+"))
        if player5213BetAmountValue then
            player5New213Amount = player5213BetAmountValue * flushPayoutReturn
            player5213BetAmount:SetText(player5New213Amount .. " G")
            player5213BetAmount:SetTextColor(0, 1, 0)

            player5213Profitvalue = player5New213Amount - player5213BetAmountValue

            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5totalWin = player5totalWin + tonumber(player5213Profitvalue)
                bankingInfo.totalWon = player5totalWin
                player5totalProfit = player5totalProfit + tonumber(player5213Profitvalue)
                bankingInfo.totalProfit = player5totalProfit
                player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5New213Amount)
                bankingInfo.bankrollTable = player5TotalBankrollAmount
            end

            historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
            historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
            if player5totalProfit >= 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        end
    else
        player5213BetAmountValue = tonumber(string.match(player5213BetAmount:GetText(), "%d+"))
        if player5213BetAmountValue then
            player5New213Amount = player5213BetAmountValue * flushPayoutReturn
            player5213BetAmount:SetText(player5New213Amount .. " G")
            player5213BetAmount:SetTextColor(0, 1, 0)
        end
    end

    player5PlaceBets213Win()
    player5213SideBetWin = true

    player5SessionWin = player5SessionWin + tonumber(player5New213Amount)

end

function player5Loss()
    player5MainBetValue = tonumber(string.match(player5MainBetAmount:GetText(), "%d+"))
    if player5MainBetValue then
        
        if playerName == unitName5 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5totalLoss = player5totalLoss + tonumber(player5MainBetValue)
                bankingInfo.totalLost = player5totalLoss
                player5totalProfit = player5totalProfit - tonumber(player5MainBetValue)
                bankingInfo.totalProfit = player5totalProfit
            end
        end

        if player5totalProfit >= 0 then
            historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

        historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
        historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")

        player5PPBetText = player5PPBetAmount:GetText()

        if player5PPBetText and player5PPBetText ~= "" then
            player5PPBetAmountValue = tonumber(string.match(player5PPBetText, "%d+"))
            
            if player5PPBetAmountValue then
                if player5PPSideBetWin == false then

                    player5PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName5 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player5totalLoss = player5totalLoss + tonumber(player5PPBetAmountValue)
                            bankingInfo.totalLost = player5totalLoss
                            player5totalProfit = player5totalProfit - tonumber(player5PPBetAmountValue)
                            bankingInfo.totalProfit = player5totalProfit
                        end
                    end
            
                    if player5totalProfit >= 0 then
                        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end
            
                    historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")

                end
            end
        end

        player5213BetText = player5213BetAmount:GetText()

        if player5213BetText and player5213BetText ~= "" then
            player5213BetAmountValue = tonumber(string.match(player5213BetText, "%d+"))

            if player5213BetAmountValue then
                if player5213SideBetWin == false then

                    player5213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName5 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player5totalLoss = player5totalLoss + tonumber(player5213BetAmountValue)
                            bankingInfo.totalLost = player5totalLoss
                            player5totalProfit = player5totalProfit - tonumber(player5213BetAmountValue)
                            bankingInfo.totalProfit = player5totalProfit
                        end
                    end
            
                    if player5totalProfit >= 0 then
                        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end
            
                    historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")

                end
            end
        end
    end
end

function player5SplitH1Loss()
    player5SplitHand1BetAmountValue = tonumber(string.match(player5SplitH1BetAmount:GetText(), "%d+"))
    if player5SplitHand1BetAmountValue then

        if playerName == unitName5 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5totalLoss = player5totalLoss + tonumber(player5SplitHand1BetAmountValue)
                bankingInfo.totalLost = player5totalLoss
                player5totalProfit = player5totalProfit - tonumber(player5SplitHand1BetAmountValue)
                bankingInfo.totalProfit = player5totalProfit
            end
        end

        historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
        historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")

        if player5totalProfit >= 0 then
            historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

    end
end

function player5SplitH2Loss()
    player5SplitHand2BetAmountValue = tonumber(string.match(player5SplitH2BetAmount:GetText(), "%d+"))
    if player5SplitHand2BetAmountValue then

        if playerName == unitName5 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5totalLoss = player5totalLoss + tonumber(player5SplitHand2BetAmountValue)
                bankingInfo.totalLost = player5totalLoss
                player5totalProfit = player5totalProfit - tonumber(player5SplitHand2BetAmountValue)
                bankingInfo.totalProfit = player5totalProfit
            end
        end

        historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
        historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")

        if player5totalProfit >= 0 then
            historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end

        player5PPBetText = player5PPBetAmount:GetText()

        if player5PPBetText and player5PPBetText ~= "" then
            player5PPBetAmountValue = tonumber(string.match(player5PPBetText, "%d+"))
            
            if player5PPBetAmountValue then
                if player5PPSideBetWin == false then

                    player5PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName5 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player5totalLoss = player5totalLoss + tonumber(player5PPBetAmountValue)
                            bankingInfo.totalLost = player5totalLoss
                            player5totalProfit = player5totalProfit - tonumber(player5PPBetAmountValue)
                            bankingInfo.totalProfit = player5totalProfit
                        end
                    end
            
                    historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
                    if player5totalProfit >= 0 then
                        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player5213BetText = player5213BetAmount:GetText()

        if player5213BetText and player5213BetText ~= "" then
            player5213BetAmountValue = tonumber(string.match(player5213BetText, "%d+"))

            if player5213BetAmountValue then
                if player5213SideBetWin == false then

                    player5213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName5 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player5totalLoss = player5totalLoss + tonumber(player5213BetAmountValue)
                            bankingInfo.totalLost = player5totalLoss
                            player5totalProfit = player5totalProfit - tonumber(player5213BetAmountValue)
                            bankingInfo.totalProfit = player5totalProfit
                        end
                    end
            
                    historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
                    if player5totalProfit >= 0 then
                        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

function player5Push()
    player5MainBetValue = tonumber(string.match(player5MainBetAmount:GetText(), "%d+"))
    if player5MainBetValue then


        if playerName == unitName5 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5MainBetValue)
                bankingInfo.bankrollTable = player5TotalBankrollAmount
            end
        end

        bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

        player5PPBetText = player5PPBetAmount:GetText()

        if player5PPBetText and player5PPBetText ~= "" then
            player5PPBetAmountValue = tonumber(string.match(player5PPBetText, "%d+"))
            
            if player5PPBetAmountValue then
                if player5PPSideBetWin == false then

                    player5PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName5 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player5totalLoss = player5totalLoss + tonumber(player5PPBetAmountValue)
                            bankingInfo.totalLost = player5totalLoss
                            player5totalProfit = player5totalProfit - tonumber(player5PPBetAmountValue)
                            bankingInfo.totalProfit = player5totalProfit
                        end
                    end
            
                    historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
                    if player5totalProfit >= 0 then
                        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player5213BetText = player5213BetAmount:GetText()

        if player5213BetText and player5213BetText ~= "" then
            player5213BetAmountValue = tonumber(string.match(player5213BetText, "%d+"))

            if player5213BetAmountValue then
                if player5213SideBetWin == false then

                    player5213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName5 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player5totalLoss = player5totalLoss + tonumber(player5213BetAmountValue)
                            bankingInfo.totalLost = player5totalLoss
                            player5totalProfit = player5totalProfit - tonumber(player5213BetAmountValue)
                            bankingInfo.totalProfit = player5totalProfit
                        end
                    end
            
                    historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
                    if player5totalProfit >= 0 then
                        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player5SessionWin = player5SessionWin + tonumber(player5MainBetValue)

    end
end

function player5SplitH1Push()
    player5SplitHand1BetAmountValue = tonumber(string.match(player5SplitH1BetAmount:GetText(), "%d+"))
    if player5SplitHand1BetAmountValue then

        if playerName == unitName5 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5SplitHand1BetAmountValue)
                bankingInfo.bankrollTable = player5TotalBankrollAmount
            end
        end

        bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
    
        player5SessionWin = player5SessionWin + tonumber(player5SplitHand1BetAmountValue)
    
    end

end

function player5SplitH2Push()
    player5SplitHand2BetAmountValue = tonumber(string.match(player5SplitH2BetAmount:GetText(), "%d+"))
    if player5SplitHand2BetAmountValue then

        if playerName == unitName5 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5SplitHand2BetAmountValue)
                bankingInfo.bankrollTable = player5TotalBankrollAmount
            end
        end

        bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

        player5PPBetText = player5PPBetAmount:GetText()

        if player5PPBetText and player5PPBetText ~= "" then
            player5PPBetAmountValue = tonumber(string.match(player5PPBetText, "%d+"))
            
            if player5PPBetAmountValue then
                if player5PPSideBetWin == false then

                    player5PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName5 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player5totalLoss = player5totalLoss + tonumber(player5PPBetAmountValue)
                            bankingInfo.totalLost = player5totalLoss
                            player5totalProfit = player5totalProfit - tonumber(player5PPBetAmountValue)
                            bankingInfo.totalProfit = player5totalProfit
                        end
                    end
            
                    historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
                    if player5totalProfit >= 0 then
                        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player5213BetText = player5213BetAmount:GetText()

        if player5213BetText and player5213BetText ~= "" then
            player5213BetAmountValue = tonumber(string.match(player5213BetText, "%d+"))

            if player5213BetAmountValue then
                if player5213SideBetWin == false then

                    player5213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName5 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player5totalLoss = player5totalLoss + tonumber(player5213BetAmountValue)
                            bankingInfo.totalLost = player5totalLoss
                            player5totalProfit = player5totalProfit - tonumber(player5213BetAmountValue)
                            bankingInfo.totalProfit = player5totalProfit
                        end
                    end
            
                    historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
                    if player5totalProfit >= 0 then
                        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player5SessionWin = player5SessionWin + tonumber(player5SplitHand2BetAmountValue)

    end
end

function player5BJWin(message)
    player5MainBetAmountValue = tonumber(string.match(player5MainBetAmount:GetText(), "%d+"))
    if player5MainBetAmountValue then
        player5BJWinAmountValue = player5MainBetAmountValue * 2.5
        player5MainBetAmount:SetText(player5BJWinAmountValue .. " G")
    end

    player5BJProfitvalue = player5BJWinAmountValue - player5MainBetAmountValue

    if playerName == unitName5 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player5totalWin = player5totalWin + tonumber(player5BJProfitvalue)
            bankingInfo.totalWon = player5totalWin
            player5totalProfit = player5totalProfit + tonumber(player5BJProfitvalue)
            bankingInfo.totalProfit = player5totalProfit
            player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5BJWinAmountValue)
            bankingInfo.bankrollTable = player5TotalBankrollAmount
        end
    end

    if player5totalProfit >= 0 then
        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
    bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
    cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

    player5PPBetText = player5PPBetAmount:GetText()

    if player5PPBetText and player5PPBetText ~= "" then
        player5PPBetAmountValue = tonumber(string.match(player5PPBetText, "%d+"))
        
        if player5PPBetAmountValue then
            if player5PPSideBetWin == false then

                player5PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName5 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player5totalLoss = player5totalLoss + tonumber(player5PPBetAmountValue)
                        bankingInfo.totalLost = player5totalLoss
                        player5totalProfit = player5totalProfit - tonumber(player5PPBetAmountValue)
                        bankingInfo.totalProfit = player5totalProfit
                    end
                end
        
                historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
        
                if player5totalProfit >= 0 then
                    historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player5213BetText = player5213BetAmount:GetText()

    if player5213BetText and player5213BetText ~= "" then
        player5213BetAmountValue = tonumber(string.match(player5213BetText, "%d+"))

        if player5213BetAmountValue then
            if player5213SideBetWin == false then

                player5213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName5 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player5totalLoss = player5totalLoss + tonumber(player5213BetAmountValue)
                        bankingInfo.totalLost = player5totalLoss
                        player5totalProfit = player5totalProfit - tonumber(player5213BetAmountValue)
                        bankingInfo.totalProfit = player5totalProfit
                    end
                end
        
                historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
        
                if player5totalProfit >= 0 then
                    historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player5MainBetCoins:Hide()
    playerFrame.player5BJWinCoins:Show()

    player5SessionWin = player5SessionWin + tonumber(player5BJWinAmountValue)

end

function player5SplitH1BJ(message)
    player5SplitHand1BetAmountValue = tonumber(string.match(player5SplitH1BetAmount:GetText(), "%d+"))
    if player5SplitHand1BetAmountValue then
        player5SplitHand1BJWinAmountValue = player5SplitHand1BetAmountValue * 2.5
        player5SplitH1BetAmount:SetText(player5SplitHand1BJWinAmountValue .. " G")
    end

    player5SplitHand1BJProfitValue = player5SplitHand1BJWinAmountValue - player5SplitHand1BetAmountValue

    if playerName == unitName5 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player5totalWin = player5totalWin + tonumber(player5SplitHand1BJProfitValue)
            bankingInfo.totalWon = player5totalWin
            player5totalProfit = player5totalProfit + tonumber(player5SplitHand1BJProfitValue)
            bankingInfo.totalProfit = player5totalProfit
            player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5SplitHand1BJWinAmountValue)
            bankingInfo.bankrollTable = player5TotalBankrollAmount
        end
    end

    if player5totalProfit >= 0 then
        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
    bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
    cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

    playerFrame.player5SplitHand1Coins:Hide()
    playerFrame.player5SplitHand1BJWinCoins:Show()

    player5SessionWin = player5SessionWin + tonumber(player5SplitHand1BJWinAmountValue)

end

function player5SplitH2BJ(message)
    player5SplitHand2BetAmountValue = tonumber(string.match(player5SplitH2BetAmount:GetText(), "%d+"))
    if player5SplitHand2BetAmountValue then
        player5SplitHand2BJWinAmountValue = player5SplitHand2BetAmountValue * 2.5
        player5SplitH2BetAmount:SetText(player5SplitHand2BJWinAmountValue .. " G")
    end

    player5SplitHand2BJProfitValue = player5SplitHand2BJWinAmountValue - player5SplitHand2BetAmountValue

    if playerName == unitName5 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player5totalWin = player5totalWin + tonumber(player5SplitHand2BJProfitValue)
            bankingInfo.totalWon = player5totalWin
            player5totalProfit = player5totalProfit + tonumber(player5SplitHand2BJProfitValue)
            bankingInfo.totalProfit = player5totalProfit
            player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5SplitHand2BJWinAmountValue)
            bankingInfo.bankrollTable = player5TotalBankrollAmount
        end
    end

    if player5totalProfit >= 0 then
        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
    bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
    cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

    player5PPBetText = player5PPBetAmount:GetText()

    if player5PPBetText and player5PPBetText ~= "" then
        player5PPBetAmountValue = tonumber(string.match(player5PPBetText, "%d+"))
        
        if player5PPBetAmountValue then
            if player5PPSideBetWin == false then

                player5PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName5 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player5totalLoss = player5totalLoss + tonumber(player5PPBetAmountValue)
                        bankingInfo.totalLost = player5totalLoss
                        player5totalProfit = player5totalProfit - tonumber(player5PPBetAmountValue)
                        bankingInfo.totalProfit = player5totalProfit
                    end
                end
        
                historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
        
                if player5totalProfit >= 0 then
                    historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player5213BetText = player5213BetAmount:GetText()

    if player5213BetText and player5213BetText ~= "" then
        player5213BetAmountValue = tonumber(string.match(player5213BetText, "%d+"))

        if player5213BetAmountValue then
            if player5213SideBetWin == false then

                player5213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName5 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player5totalLoss = player5totalLoss + tonumber(player5213BetAmountValue)
                        bankingInfo.totalLost = player5totalLoss
                        player5totalProfit = player5totalProfit - tonumber(player5213BetAmountValue)
                        bankingInfo.totalProfit = player5totalProfit
                    end
                end
        
                historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
        
                if player5totalProfit >= 0 then
                    historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player5SplitHand2Coins:Hide()
    playerFrame.player5SplitHand2BJWinCoins:Show()

    player5SessionWin = player5SessionWin + tonumber(player5SplitHand2BJWinAmountValue)

end

function player5Win(message)
    player5MainBetAmountValue = tonumber(string.match(player5MainBetAmount:GetText(), "%d+"))
    if player5MainBetAmountValue then
        player5NormalWinAmountValue = player5MainBetAmountValue * 2
        player5MainBetAmount:SetText(player5NormalWinAmountValue .. " G")

        if playerName == unitName5 then
            if playerBankingInfo[playerName] then
                bankingInfo = playerBankingInfo[playerName]
                player5totalWin = player5totalWin + tonumber(player5MainBetAmountValue)
                bankingInfo.totalWon = player5totalWin
                player5totalProfit = player5totalProfit + tonumber(player5MainBetAmountValue)
                bankingInfo.totalProfit = player5totalProfit
                player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5NormalWinAmountValue)
                bankingInfo.bankrollTable = player5TotalBankrollAmount
            end
        end
    
        if player5totalProfit >= 0 then
            historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
        else
            historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
        end
    
        historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
        historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
        bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

        player5PPBetText = player5PPBetAmount:GetText()

        if player5PPBetText and player5PPBetText ~= "" then
            player5PPBetAmountValue = tonumber(string.match(player5PPBetText, "%d+"))
            
            if player5PPBetAmountValue then
                if player5PPSideBetWin == false then

                    player5PPBetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName5 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player5totalLoss = player5totalLoss + tonumber(player5PPBetAmountValue)
                            bankingInfo.totalLost = player5totalLoss
                            player5totalProfit = player5totalProfit - tonumber(player5PPBetAmountValue)
                            bankingInfo.totalProfit = player5totalProfit
                        end
                    end
            
                    historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
                    if player5totalProfit >= 0 then
                        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        player5213BetText = player5213BetAmount:GetText()

        if player5213BetText and player5213BetText ~= "" then
            player5213BetAmountValue = tonumber(string.match(player5213BetText, "%d+"))

            if player5213BetAmountValue then
                if player5213SideBetWin == false then

                    player5213BetAmount:SetTextColor(1, 0, 0)

                    if playerName == unitName5 then
                        if playerBankingInfo[playerName] then
                            bankingInfo = playerBankingInfo[playerName]
                            player5totalLoss = player5totalLoss + tonumber(player5213BetAmountValue)
                            bankingInfo.totalLost = player5totalLoss
                            player5totalProfit = player5totalProfit - tonumber(player5213BetAmountValue)
                            bankingInfo.totalProfit = player5totalProfit
                        end
                    end
            
                    historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            
                    if player5totalProfit >= 0 then
                        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                    else
                        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end

    playerFrame.player5MainBetCoins:Hide()
    playerFrame.player5NormalWinCoins:Show()

    player5SessionWin = player5SessionWin + tonumber(player5NormalWinAmountValue)

end

function player5SplitH1Win(message)
    player5SplitHand1BetAmountValue = tonumber(string.match(player5SplitH1BetAmount:GetText(), "%d+"))
    if player5SplitHand1BetAmountValue then
        player5SplitHand1NormalWinAmountValue = player5SplitHand1BetAmountValue * 2
        player5SplitH1BetAmount:SetText(player5SplitHand1NormalWinAmountValue .. " G")
    end

    if playerName == unitName5 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player5totalWin = player5totalWin + tonumber(player5SplitHand1BetAmountValue)
            bankingInfo.totalWon = player5totalWin
            player5totalProfit = player5totalProfit + tonumber(player5SplitHand1BetAmountValue)
            bankingInfo.totalProfit = player5totalProfit
            player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5SplitHand1NormalWinAmountValue)
            bankingInfo.bankrollTable = player5TotalBankrollAmount
        end
    end

    if player5totalProfit >= 0 then
        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
    bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
    cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

    playerFrame.player5SplitHand1Coins:Hide()
    playerFrame.player5SplitHand1NormalWinCoins:Show()

    player5SessionWin = player5SessionWin + tonumber(player5SplitHand1NormalWinAmountValue)

end

function player5SplitH2Win(message)
    player5SplitHand2BetAmountValue = tonumber(string.match(player5SplitH2BetAmount:GetText(), "%d+"))
    if player5SplitHand2BetAmountValue then
        player5SplitHand2NormalWinAmountValue = player5SplitHand2BetAmountValue * 2
        player5SplitH2BetAmount:SetText(player5SplitHand2NormalWinAmountValue .. " G")
    end

    if playerName == unitName5 then
        if playerBankingInfo[playerName] then
            bankingInfo = playerBankingInfo[playerName]
            player5totalWin = player5totalWin + tonumber(player5SplitHand2BetAmountValue)
            bankingInfo.totalWon = player5totalWin
            player5totalProfit = player5totalProfit + tonumber(player5SplitHand2BetAmountValue)
            bankingInfo.totalProfit = player5totalProfit
            player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5SplitHand2NormalWinAmountValue)
            bankingInfo.bankrollTable = player5TotalBankrollAmount
        end
    end

    if player5totalProfit >= 0 then
        historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
    else
        historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
    end

    historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
    historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
    bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
    cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

    player5PPBetText = player5PPBetAmount:GetText()

    if player5PPBetText and player5PPBetText ~= "" then
        player5PPBetAmountValue = tonumber(string.match(player5PPBetText, "%d+"))
        
        if player5PPBetAmountValue then
            if player5PPSideBetWin == false then

                player5PPBetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName5 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player5totalLoss = player5totalLoss + tonumber(player5PPBetAmountValue)
                        bankingInfo.totalLost = player5totalLoss
                        player5totalProfit = player5totalProfit - tonumber(player5PPBetAmountValue)
                        bankingInfo.totalProfit = player5totalProfit
                    end
                end
        
                historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
        
                if player5totalProfit >= 0 then
                    historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player5213BetText = player5213BetAmount:GetText()

    if player5213BetText and player5213BetText ~= "" then
        player5213BetAmountValue = tonumber(string.match(player5213BetText, "%d+"))

        if player5213BetAmountValue then
            if player5213SideBetWin == false then

                player5213BetAmount:SetTextColor(1, 0, 0)

                if playerName == unitName5 then
                    if playerBankingInfo[playerName] then
                        bankingInfo = playerBankingInfo[playerName]
                        player5totalLoss = player5totalLoss + tonumber(player5213BetAmountValue)
                        bankingInfo.totalLost = player5totalLoss
                        player5totalProfit = player5totalProfit - tonumber(player5213BetAmountValue)
                        bankingInfo.totalProfit = player5totalProfit
                    end
                end
        
                historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
                historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
        
                if player5totalProfit >= 0 then
                    historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
                else
                    historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    playerFrame.player5SplitHand2Coins:Hide()
    playerFrame.player5SplitHand2NormalWinCoins:Show()

    player5SessionWin = player5SessionWin + tonumber(player5SplitHand2NormalWinAmountValue)

end

function player5InsuranceWin(message)

    player5InsuranceBetText = playerFrame.player5InsuranceBetAmount:GetText()

    if player5InsuranceBetText and player5InsuranceBetText ~= "" then
        player5InsuranceBetAmountValue = tonumber(string.match(player5InsuranceBetText, "%d+"))

        if player5InsuranceBetAmountValue then
            player5InsuranceWinAmountValue = player5InsuranceBetAmountValue * 3

            player5InsuranceProfitValue = player5InsuranceWinAmountValue - player5InsuranceBetAmountValue


            if playerName == unitName5 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player5totalWin = player5totalWin + tonumber(player5InsuranceProfitValue)
                    bankingInfo.totalWon = player5totalWin
                    player5totalProfit = player5totalProfit + tonumber(player5InsuranceProfitValue)
                    bankingInfo.totalProfit = player5totalProfit
                    player5TotalBankrollAmount = player5TotalBankrollAmount + tonumber(player5InsuranceWinAmountValue)
                    bankingInfo.bankrollTable = player5TotalBankrollAmount
                end
            end
        
            if player5totalProfit >= 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
        
            historyFrame.player5totalWonAmount:SetText(player5totalWin .. " G")
            historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")
            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")

            player5SessionWin = player5SessionWin + tonumber(player5InsuranceWinAmountValue)

        end
    end
end

function player5InsuranceLoss(message)

    player5InsuranceBetText = playerFrame.player5InsuranceBetAmount:GetText()

    if player5InsuranceBetText and player5InsuranceBetText ~= "" then
        player5InsuranceBetAmountValue = tonumber(string.match(player5InsuranceBetText, "%d+"))

        if player5InsuranceBetAmountValue then

            if playerName == unitName5 then
                if playerBankingInfo[playerName] then
                    bankingInfo = playerBankingInfo[playerName]
                    player5totalLoss = player5totalLoss + tonumber(player5InsuranceBetAmountValue)
                    bankingInfo.totalLost = player5totalLoss
                    player5totalProfit = player5totalProfit - tonumber(player5InsuranceBetAmountValue)
                    bankingInfo.totalProfit = player5totalProfit
                end
            end
    
            if player5totalProfit >= 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            else
                historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
    
            historyFrame.player5totalLostAmount:SetText(player5totalLoss .. " G")
            historyFrame.player5ProfitAmount:SetText(player5totalProfit .. " G")

        end
    end
end

function player5SessionWinAnnouncement()
    if playerName == unitName5 then
        if player5SessionWinCalled == false then
            if player5SessionWin >= 50 then
                chatFrame = SELECTED_DOCK_FRAME
                ChatFrame_OpenChat("/me", chatFrame)
                
                editBox = _G[chatFrame:GetName().."EditBox"]
                editBox:SetText("")
                editBox:Insert("/me has won " .. player5SessionWin .. "g from a hand of Blackjack.")
                
                ChatEdit_SendText(editBox)
                ChatEdit_DeactivateChat(editBox)

                UpdateWinningsDisplay(playerFrame.player5WinningsUpdate, player5SessionWin)
                player5resetRaidChannel()
                
            else
                print("")
            end

            player5SessionWinCalled = true
        end
    end
end











-- >> TIMERS <<
-- >> TIMERS <<
-- >> TIMERS <<

-- >> PLAYER 1 <<
function player1UpdateTimerDisplay(secondsRemaining)
    timerFrame.player1TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player1OnTimerUpdate()
    countdownDuration = countdownDuration - 1
    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player1HitButton:Disable()
        playerFrame.player1StandButton:Disable()
        playerFrame.player1DoubleButton:Disable()
        playerFrame.player1SplitButton:Disable()
        playerFrame.player1InsuranceYesButton:Disable()
        playerFrame.player1InsuranceNoButton:Disable()

        -- Players: 1
        if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player1CountdownTimer:Cancel()
        timerFrame.player1TimerText:SetText("Time is up!")
        timerFrame.player1TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName1 then
            SendChatMessage("[P1] Stand", "RAID")
        end
    else
        player1UpdateTimerDisplay(countdownDuration)
    end
end
function player1StartCountdown()
    if player1CountdownTimer then
        player1CountdownTimer:Cancel()
    end
    player1CountdownTimer = C_Timer.NewTicker(1, player1OnTimerUpdate, countdownDuration)
    timerFrame.player1TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player1TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player1TimerText:Show()
    timerFrame.player1TimerText:SetTextColor(1, 1, 1)
end
function player1SplitH1UpdateTimerDisplay(secondsRemaining)
    timerFrame.player1TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player1SplitH1OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player1HitButtonSplitH1:Disable()
        playerFrame.player1StandButtonSplitH1:Disable()
        playerFrame.player1DoubleButtonSplitH1:Disable()

        -- Players: 1
        if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
            turn = 16

        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player1SplitH1CountdownTimer:Cancel()
        timerFrame.player1TimerText:SetText("Time is up!")
        timerFrame.player1TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName1 then
            SendChatMessage("[P1] (H1) Stand", "RAID")
        end
    else
        player1SplitH1UpdateTimerDisplay(countdownDuration)
    end
end
function player1SplitH1StartCountdown()
    if player1SplitH1CountdownTimer then
        player1SplitH1CountdownTimer:Cancel()
    end
    player1SplitH1CountdownTimer = C_Timer.NewTicker(1, player1SplitH1OnTimerUpdate, countdownDuration)
    timerFrame.player1TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player1TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player1TimerText:Show()
    timerFrame.player1TimerText:SetTextColor(1, 1, 1)
end
function player1SplitH2UpdateTimerDisplay(secondsRemaining)
    timerFrame.player1TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player1SplitH2OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player1HitButtonSplitH2:Disable()
        playerFrame.player1StandButtonSplitH2:Disable()
        playerFrame.player1DoubleButtonSplitH2:Disable()

        -- Players: 1
        if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player1SplitH2CountdownTimer:Cancel()
        timerFrame.player1TimerText:SetText("Time is up!")
        timerFrame.player1TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName1 then
            SendChatMessage("[P1] (H2) Stand", "RAID")
        end
    else
        player1SplitH2UpdateTimerDisplay(countdownDuration)
    end
end
function player1SplitH2StartCountdown()
    if player1SplitH2CountdownTimer then
        player1SplitH2CountdownTimer:Cancel()
    end
    player1SplitH2CountdownTimer = C_Timer.NewTicker(1, player1SplitH2OnTimerUpdate, countdownDuration)
    timerFrame.player1TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player1TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player1TimerText:Show()
    timerFrame.player1TimerText:SetTextColor(1, 1, 1)
end
-- >> PLAYER 2 <<
function player2UpdateTimerDisplay(secondsRemaining)
    timerFrame.player2TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player2OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player2HitButton:Disable()
        playerFrame.player2StandButton:Disable()
        playerFrame.player2DoubleButton:Disable()
        playerFrame.player2SplitButton:Disable()
        playerFrame.player2InsuranceYesButton:Disable()
        playerFrame.player2InsuranceNoButton:Disable()

        -- Players: 2
        if not player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player2CountdownTimer:Cancel()
        timerFrame.player2TimerText:SetText("Time is up!")
        timerFrame.player2TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName2 then
            SendChatMessage("[P2] Stand", "RAID")
        end
    else
        player2UpdateTimerDisplay(countdownDuration)
    end
end
function player2StartCountdown()
    if player2CountdownTimer then
        player2CountdownTimer:Cancel()
    end
    player2CountdownTimer = C_Timer.NewTicker(1, player2OnTimerUpdate, countdownDuration)
    timerFrame.player2TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player2TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player2TimerText:Show()
    timerFrame.player2TimerText:SetTextColor(1, 1, 1)
end
function player2SplitH1UpdateTimerDisplay(secondsRemaining)
    timerFrame.player2TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player2SplitH1OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player2HitButtonSplitH1:Disable()
        playerFrame.player2StandButtonSplitH1:Disable()
        playerFrame.player2DoubleButtonSplitH1:Disable()

        -- Players: 2
        if not player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
            turn = 16

        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player2SplitH1CountdownTimer:Cancel()
        timerFrame.player2TimerText:SetText("Time is up!")
        timerFrame.player2TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName2 then
            SendChatMessage("[P2] (H1) Stand", "RAID")
        end
    else
        player2SplitH1UpdateTimerDisplay(countdownDuration)
    end
end
function player2SplitH1StartCountdown()
    if player2SplitH1CountdownTimer then
        player2SplitH1CountdownTimer:Cancel()
    end
    player2SplitH1CountdownTimer = C_Timer.NewTicker(1, player2SplitH1OnTimerUpdate, countdownDuration)
    timerFrame.player2TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player2TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player2TimerText:Show()
    timerFrame.player2TimerText:SetTextColor(1, 1, 1)
end
function player2SplitH2UpdateTimerDisplay(secondsRemaining)
    timerFrame.player2TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player2SplitH2OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player2HitButtonSplitH2:Disable()
        playerFrame.player2StandButtonSplitH2:Disable()
        playerFrame.player2DoubleButtonSplitH2:Disable()

        -- Players: 2
        if not player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player2SplitH2CountdownTimer:Cancel()
        timerFrame.player2TimerText:SetText("Time is up!")
        timerFrame.player2TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName2 then
            SendChatMessage("[P2] (H2) Stand", "RAID")
        end
    else
        player2SplitH2UpdateTimerDisplay(countdownDuration)
    end
end
function player2SplitH2StartCountdown()
    if player2SplitH2CountdownTimer then
        player2SplitH2CountdownTimer:Cancel()
    end
    player2SplitH2CountdownTimer = C_Timer.NewTicker(1, player2SplitH2OnTimerUpdate, countdownDuration)
    timerFrame.player2TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player2TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player2TimerText:Show()
    timerFrame.player2TimerText:SetTextColor(1, 1, 1)
end
-- >> PLAYER 3 <<
function player3UpdateTimerDisplay(secondsRemaining)
    timerFrame.player3TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player3OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player3HitButton:Disable()
        playerFrame.player3StandButton:Disable()
        playerFrame.player3DoubleButton:Disable()
        playerFrame.player3SplitButton:Disable()
        playerFrame.player3InsuranceYesButton:Disable()
        playerFrame.player3InsuranceNoButton:Disable()

        -- Players: 3
        if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player3CountdownTimer:Cancel()
        timerFrame.player3TimerText:SetText("Time is up!")
        timerFrame.player3TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName3 then
            SendChatMessage("[P3] Stand", "RAID")
        end
    else
        player3UpdateTimerDisplay(countdownDuration)
    end
end
function player3StartCountdown()
    if player3CountdownTimer then
        player3CountdownTimer:Cancel()
    end
    player3CountdownTimer = C_Timer.NewTicker(1, player3OnTimerUpdate, countdownDuration)
    timerFrame.player3TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player3TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player3TimerText:Show()
    timerFrame.player3TimerText:SetTextColor(1, 1, 1)
end
function player3SplitH1UpdateTimerDisplay(secondsRemaining)
    timerFrame.player3TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player3SplitH1OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player3HitButtonSplitH1:Disable()
        playerFrame.player3StandButtonSplitH1:Disable()
        playerFrame.player3DoubleButtonSplitH1:Disable()

        -- Players: 3
        if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 16

        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player3SplitH1CountdownTimer:Cancel()
        timerFrame.player3TimerText:SetText("Time is up!")
        timerFrame.player3TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName3 then
            SendChatMessage("[P3] (H1) Stand", "RAID")
        end
    else
        player3SplitH1UpdateTimerDisplay(countdownDuration)
    end
end
function player3SplitH1StartCountdown()
    if player3SplitH1CountdownTimer then
        player3SplitH1CountdownTimer:Cancel()
    end
    player3SplitH1CountdownTimer = C_Timer.NewTicker(1, player3SplitH1OnTimerUpdate, countdownDuration)
    timerFrame.player3TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player3TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player3TimerText:Show()
    timerFrame.player3TimerText:SetTextColor(1, 1, 1)
end
function player3SplitH2UpdateTimerDisplay(secondsRemaining)
    timerFrame.player3TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player3SplitH2OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player3HitButtonSplitH2:Disable()
        playerFrame.player3StandButtonSplitH2:Disable()
        playerFrame.player3DoubleButtonSplitH2:Disable()

        -- Players: 3
        if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            turn = 11
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player3SplitH2CountdownTimer:Cancel()
        timerFrame.player3TimerText:SetText("Time is up!")
        timerFrame.player3TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName3 then
            SendChatMessage("[P3] (H2) Stand", "RAID")
        end
    else
        player3SplitH2UpdateTimerDisplay(countdownDuration)
    end
end
function player3SplitH2StartCountdown()
    if player3SplitH2CountdownTimer then
        player3SplitH2CountdownTimer:Cancel()
    end
    player3SplitH2CountdownTimer = C_Timer.NewTicker(1, player3SplitH2OnTimerUpdate, countdownDuration)
    timerFrame.player3TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player3TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player3TimerText:Show()
    timerFrame.player3TimerText:SetTextColor(1, 1, 1)
end
-- >> PLAYER 4 <<
function player4UpdateTimerDisplay(secondsRemaining)
    timerFrame.player4TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player4OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player4HitButton:Disable()
        playerFrame.player4StandButton:Disable()
        playerFrame.player4DoubleButton:Disable()
        playerFrame.player4SplitButton:Disable()
        playerFrame.player4InsuranceYesButton:Disable()
        playerFrame.player4InsuranceNoButton:Disable()

        -- Players: 4
        if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 23

        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player4CountdownTimer:Cancel()
        timerFrame.player4TimerText:SetText("Time is up!")
        timerFrame.player4TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName4 then
            SendChatMessage("[P4] Stand", "RAID")
        end
    else
        player4UpdateTimerDisplay(countdownDuration)
    end
end
function player4StartCountdown()
    if player4CountdownTimer then
        player4CountdownTimer:Cancel()
    end
    player4CountdownTimer = C_Timer.NewTicker(1, player4OnTimerUpdate, countdownDuration)
    timerFrame.player4TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player4TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player4TimerText:Show()
    timerFrame.player4TimerText:SetTextColor(1, 1, 1)
end
function player4SplitH1UpdateTimerDisplay(secondsRemaining)
    timerFrame.player4TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player4SplitH1OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player4HitButtonSplitH1:Disable()
        playerFrame.player4StandButtonSplitH1:Disable()
        playerFrame.player4DoubleButtonSplitH1:Disable()

        -- Players: 4
        if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 16

        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player4SplitH1CountdownTimer:Cancel()
        timerFrame.player4TimerText:SetText("Time is up!")
        timerFrame.player4TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName4 then
            SendChatMessage("[P4] (H1) Stand", "RAID")
        end
    else
        player4SplitH1UpdateTimerDisplay(countdownDuration)
    end
end
function player4SplitH1StartCountdown()
    if player4SplitH1CountdownTimer then
        player4SplitH1CountdownTimer:Cancel()
    end
    player4SplitH1CountdownTimer = C_Timer.NewTicker(1, player4SplitH1OnTimerUpdate, countdownDuration)
    timerFrame.player4TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player4TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player4TimerText:Show()
    timerFrame.player4TimerText:SetTextColor(1, 1, 1)
end
function player4SplitH2UpdateTimerDisplay(secondsRemaining)
    timerFrame.player4TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player4SplitH2OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player4HitButtonSplitH2:Disable()
        playerFrame.player4StandButtonSplitH2:Disable()
        playerFrame.player4DoubleButtonSplitH2:Disable()

        -- Players: 4
        if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 23

        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            turn = 11
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 13
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player4SplitH2CountdownTimer:Cancel()
        timerFrame.player4TimerText:SetText("Time is up!")
        timerFrame.player4TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName4 then
            SendChatMessage("[P4] (H2) Stand", "RAID")
        end
    else
        player4SplitH2UpdateTimerDisplay(countdownDuration)
    end
end
function player4SplitH2StartCountdown()
    if player4SplitH2CountdownTimer then
        player4SplitH2CountdownTimer:Cancel()
    end
    player4SplitH2CountdownTimer = C_Timer.NewTicker(1, player4SplitH2OnTimerUpdate, countdownDuration)
    timerFrame.player4TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player4TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player4TimerText:Show()
    timerFrame.player4TimerText:SetTextColor(1, 1, 1)
end
-- >> PLAYER 5 <<
function player5UpdateTimerDisplay(secondsRemaining)
    timerFrame.player5TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player5OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player5HitButton:Disable()
        playerFrame.player5StandButton:Disable()
        playerFrame.player5DoubleButton:Disable()
        playerFrame.player5SplitButton:Disable()
        playerFrame.player5InsuranceYesButton:Disable()
        playerFrame.player5InsuranceNoButton:Disable()

        -- Players: 5
        if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 23

        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 11
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            turn = 11
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            turn = 11
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player5CountdownTimer:Cancel()
        timerFrame.player5TimerText:SetText("Time is up!")
        timerFrame.player5TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName5 then
            SendChatMessage("[P5] Stand", "RAID")
        end
    else
        player5UpdateTimerDisplay(countdownDuration)
    end
end
function player5StartCountdown()
    if player5CountdownTimer then
        player5CountdownTimer:Cancel()
    end
    player5CountdownTimer = C_Timer.NewTicker(1, player5OnTimerUpdate, countdownDuration)
    timerFrame.player5TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player5TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player5TimerText:Show()
    timerFrame.player5TimerText:SetTextColor(1, 1, 1)
end
function player5SplitH1UpdateTimerDisplay(secondsRemaining)
    timerFrame.player5TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player5SplitH1OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player5HitButtonSplitH1:Disable()
        playerFrame.player5StandButtonSplitH1:Disable()
        playerFrame.player5DoubleButtonSplitH1:Disable()

        -- Players: 5
        if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 16

        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 11
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            turn = 11
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            turn = 11
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player5SplitH1CountdownTimer:Cancel()
        timerFrame.player5TimerText:SetText("Time is up!")
        timerFrame.player5TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName5 then
            SendChatMessage("[P5] (H1) Stand", "RAID")
        end
    else
        player5SplitH1UpdateTimerDisplay(countdownDuration)
    end
end
function player5SplitH1StartCountdown()
    if player5SplitH1CountdownTimer then
        player5SplitH1CountdownTimer:Cancel()
    end
    player5SplitH1CountdownTimer = C_Timer.NewTicker(1, player5SplitH1OnTimerUpdate, countdownDuration)
    timerFrame.player5TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player5TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player5TimerText:Show()
    timerFrame.player5TimerText:SetTextColor(1, 1, 1)
end
function player5SplitH2UpdateTimerDisplay(secondsRemaining)
    timerFrame.player5TimerText:SetText("Timer: " .. secondsRemaining .. " s remaining")
end
function player5SplitH2OnTimerUpdate()
    countdownDuration = countdownDuration - 1

    if countdownDuration == 10 then
        PlaySoundFile(soundFilePaths[118])

    elseif countdownDuration <= 0 then
        playerFrame.player5HitButtonSplitH2:Disable()
        playerFrame.player5StandButtonSplitH2:Disable()
        playerFrame.player5DoubleButtonSplitH2:Disable()

        -- Players: 5
        if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 23

        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 11
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            turn = 11
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            turn = 11
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            turn = 11

        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 13
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 13
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 13

        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 15
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 15
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 15

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 17
        end

        player5SplitH2CountdownTimer:Cancel()
        timerFrame.player5TimerText:SetText("Time is up!")
        timerFrame.player5TimerText:SetTextColor(1, 0, 0)

        if playerName == unitName5 then
            SendChatMessage("[P5] (H2) Stand", "RAID")
        end
    else
        player5SplitH2UpdateTimerDisplay(countdownDuration)
    end
end
function player5SplitH2StartCountdown()
    if player5SplitH2CountdownTimer then
        player5SplitH2CountdownTimer:Cancel()
    end
    player5SplitH2CountdownTimer = C_Timer.NewTicker(1, player5SplitH2OnTimerUpdate, countdownDuration)
    timerFrame.player5TimerText:SetPoint("CENTER", timerFrame, 0, 0)
    timerFrame.player5TimerText:SetJustifyH("CENTER")
    timerFrame:Show()
    timerFrame.player5TimerText:Show()
    timerFrame.player5TimerText:SetTextColor(1, 1, 1)
end
-- >> PLACE BETS <<
function UpdateTimerDisplayBets(secondsRemaining)
    timerBetsFrame.timerTextBets:SetText("Place your bets!\nTimer: " .. secondsRemaining .. " s remaining")
end
function OnTimerUpdateBets()
    countdownDuration = countdownDuration - 1

    if countdownDuration <= 0 then
        player1ConfirmMainBetButton:Disable()
        player1ConfirmPPBetButton:Disable()
        player1Confirm213BetButton:Disable()
        player1PreloadBetButton:Disable()
        player2ConfirmMainBetButton:Disable()
        player2ConfirmPPBetButton:Disable()
        player2Confirm213BetButton:Disable()
        player2PreloadBetButton:Disable()
        player3ConfirmMainBetButton:Disable()
        player3ConfirmPPBetButton:Disable()
        player3Confirm213BetButton:Disable()
        player3PreloadBetButton:Disable()
        player4ConfirmMainBetButton:Disable()
        player4ConfirmPPBetButton:Disable()
        player4Confirm213BetButton:Disable()
        player4PreloadBetButton:Disable()
        player5ConfirmMainBetButton:Disable()
        player5ConfirmPPBetButton:Disable()
        player5Confirm213BetButton:Disable()
        player5PreloadBetButton:Disable()
        countdownTimerBets:Cancel()
        timerBetsFrame.timerTextBets:SetText("No more bets!")
        timerBetsFrame.timerTextBets:SetJustifyH("CENTER")
        timerBetsFrame.timerTextBets:SetTextColor(1, 1, 0)
    else
        UpdateTimerDisplayBets(countdownDuration)
    end
end
function StartCountdownTimerBets()
    if countdownTimerBets then
        countdownTimerBets:Cancel()
    end
    countdownTimerBets = C_Timer.NewTicker(1, OnTimerUpdateBets, countdownDuration)
    timerBetsFrame:Show()
    timerBetsFrame.timerTextBets:Show()
    timerBetsFrame.timerTextBets:SetTextColor(1, 1, 1)
end









-- >> TURNS <<
-- >> TURNS <<
-- >> TURNS <<

-- >> PLAYER 1 <<
function player1Turn()
    playerFrame.player1HitButton:Enable()
    playerFrame.player1StandButton:Enable()
    if player1DoubleToggle == false then
        playerFrame.player1DoubleButton:Enable()
    else
        playerFrame.player1DoubleButton:Disable()
    end
end
function player1SplitHand1Turn()
    playerFrame.player1HitButtonSplitH1:Enable()
    playerFrame.player1StandButtonSplitH1:Enable()
    if player1DoubleHand1Toggle == false then
        playerFrame.player1DoubleButtonSplitH1:Enable()
    else
        playerFrame.player1DoubleButtonSplitH1:Disable()
    end
end
function player1SplitHand2Turn()
    playerFrame.player1HitButtonSplitH2:Enable()
    playerFrame.player1StandButtonSplitH2:Enable()
    if player1DoubleHand2Toggle == false then
        playerFrame.player1DoubleButtonSplitH2:Enable()
    else
        playerFrame.player1DoubleButtonSplitH2:Disable()
    end
end
-- >> PLAYER 2 <<
function player2Turn()
    playerFrame.player2HitButton:Enable()
    playerFrame.player2StandButton:Enable()
    if player2DoubleToggle == false then
        playerFrame.player2DoubleButton:Enable()
    else
        playerFrame.player2DoubleButton:Disable()
    end
end
function player2SplitHand1Turn()
    playerFrame.player2HitButtonSplitH1:Enable()
    playerFrame.player2StandButtonSplitH1:Enable()
    if player2DoubleHand1Toggle == false then
        playerFrame.player2DoubleButtonSplitH1:Enable()
    else
        playerFrame.player2DoubleButtonSplitH1:Disable()
    end
end
function player2SplitHand2Turn()
    playerFrame.player2HitButtonSplitH2:Enable()
    playerFrame.player2StandButtonSplitH2:Enable()
    if player2DoubleHand2Toggle == false then
        playerFrame.player2DoubleButtonSplitH2:Enable()
    else
        playerFrame.player2DoubleButtonSplitH2:Disable()
    end
end
-- >> PLAYER 3 <<
function player3Turn()
    playerFrame.player3HitButton:Enable()
    playerFrame.player3StandButton:Enable()
    if player3DoubleToggle == false then
        playerFrame.player3DoubleButton:Enable()
    else
        playerFrame.player3DoubleButton:Disable()
    end
end
function player3SplitHand1Turn()
    playerFrame.player3HitButtonSplitH1:Enable()
    playerFrame.player3StandButtonSplitH1:Enable()
    if player3DoubleHand1Toggle == false then
        playerFrame.player3DoubleButtonSplitH1:Enable()
    else
        playerFrame.player3DoubleButtonSplitH1:Disable()
    end
end
function player3SplitHand2Turn()
    playerFrame.player3HitButtonSplitH2:Enable()
    playerFrame.player3StandButtonSplitH2:Enable()
    if player3DoubleHand2Toggle == false then
        playerFrame.player3DoubleButtonSplitH2:Enable()
    else
        playerFrame.player3DoubleButtonSplitH2:Disable()
    end
end
-- >> PLAYER 4 <<
function player4Turn()
    playerFrame.player4HitButton:Enable()
    playerFrame.player4StandButton:Enable()
    if player4DoubleToggle == false then
        playerFrame.player4DoubleButton:Enable()
    else
        playerFrame.player4DoubleButton:Disable()
    end
end
function player4SplitHand1Turn()
    playerFrame.player4HitButtonSplitH1:Enable()
    playerFrame.player4StandButtonSplitH1:Enable()
    if player4DoubleHand1Toggle == false then
        playerFrame.player4DoubleButtonSplitH1:Enable()
    else
        playerFrame.player4DoubleButtonSplitH1:Disable()
    end
end
function player4SplitHand2Turn()
    playerFrame.player4HitButtonSplitH2:Enable()
    playerFrame.player4StandButtonSplitH2:Enable()
    if player4DoubleHand2Toggle == false then
        playerFrame.player4DoubleButtonSplitH2:Enable()
    else
        playerFrame.player4DoubleButtonSplitH2:Disable()
    end
end
-- >> PLAYER 5 <<
function player5Turn()
    playerFrame.player5HitButton:Enable()
    playerFrame.player5StandButton:Enable()
    if player5DoubleToggle == false then
        playerFrame.player5DoubleButton:Enable()
    else
        playerFrame.player5DoubleButton:Disable()
    end
end
function player5SplitHand1Turn()
    playerFrame.player5HitButtonSplitH1:Enable()
    playerFrame.player5StandButtonSplitH1:Enable()
    if player5DoubleHand1Toggle == false then
        playerFrame.player5DoubleButtonSplitH1:Enable()
    else
        playerFrame.player5DoubleButtonSplitH1:Disable()
    end
end
function player5SplitHand2Turn()
    playerFrame.player5HitButtonSplitH2:Enable()
    playerFrame.player5StandButtonSplitH2:Enable()
    if player5DoubleHand2Toggle == false then
        playerFrame.player5DoubleButtonSplitH2:Enable()
    else
        playerFrame.player5DoubleButtonSplitH2:Disable()
    end
end









-- >> CARD DISPLAYS <<
-- >> CARD DISPLAYS <<
-- >> CARD DISPLAYS <<

function P12345(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 5 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 67 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 68 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 69 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 70 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 71 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 72 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 73 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 74 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 75 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 76 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 77 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 78 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 79 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 80 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 81 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 82 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 83 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 84 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 85 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 86 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 87 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 88 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 89 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 90 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 91 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 92 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 93 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 94 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 95 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 96 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 97 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 98 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 99 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 100 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 101 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 102 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 103 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 104 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 105 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 106 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 107 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 108 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 109 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 110 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 111 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 112 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 113 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 114 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 115 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 116 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end


        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 109 then
            turn = 111
        else
            turn = turn + 1
        end
    end
end

function P2345(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 4 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 67 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 68 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 69 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 70 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 71 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 72 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 73 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 74 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 75 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 76 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 77 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 78 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 79 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 80 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 81 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 82 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 83 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 84 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 85 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 86 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 87 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 88 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 89 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 90 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 91 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 92 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 93 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 94 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end


        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 87 then
            turn = 89
        else
            turn = turn + 1
        end
    end
end
function P1345(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 4 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 67 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 68 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 69 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 70 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 71 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 72 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 73 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 74 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 75 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 76 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 77 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 78 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 79 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 80 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 81 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 82 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 83 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 84 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 85 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 86 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 87 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 88 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 89 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 90 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 91 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 92 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 93 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 94 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end


        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 87 then
            turn = 89
        else
            turn = turn + 1
        end
    end
end
function P1245(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 4 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 67 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 68 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 69 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 70 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 71 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 72 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 73 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 74 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 75 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 76 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 77 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 78 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 79 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 80 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 81 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 82 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 83 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 84 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 85 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 86 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 87 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 88 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 89 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 90 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 91 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 92 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 93 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 94 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end


        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 87 then
            turn = 89
        else
            turn = turn + 1
        end
    end
end
function P1235(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 4 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 67 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 68 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 69 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 70 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 71 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 72 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 73 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 74 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 75 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 76 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 77 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 78 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 79 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 80 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 81 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 82 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 83 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 84 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 85 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 86 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 87 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 88 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 89 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 90 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 91 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 92 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 93 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 94 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end


        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 87 then
            turn = 89
        else
            turn = turn + 1
        end
    end
end
function P1234(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 4 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 67 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 68 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 69 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 70 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 71 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 72 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 73 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 74 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 75 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 76 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 77 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 78 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 79 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 80 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 81 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 82 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 83 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 84 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 85 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 86 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 87 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 88 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 89 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 90 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 91 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 92 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 93 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 94 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end


        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 87 then
            turn = 89
        else
            turn = turn + 1
        end
    end
end

function P345(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 3 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 67 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 68 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 69 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 70 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 71 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 72 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 65 then
            turn = 67
        else
            turn = turn + 1
        end
    end
end
function P245(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 3 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 67 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 68 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 69 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 70 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 71 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 72 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 65 then
            turn = 67
        else
            turn = turn + 1
        end
    end
end
function P235(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 3 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 67 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 68 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 69 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 70 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 71 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 72 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 65 then
            turn = 67
        else
            turn = turn + 1
        end
    end
end
function P234(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 3 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 67 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 68 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 69 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 70 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 71 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 72 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 65 then
            turn = 67
        else
            turn = turn + 1
        end
    end
end
function P145(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 3 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 67 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 68 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 69 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 70 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 71 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 72 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 65 then
            turn = 67
        else
            turn = turn + 1
        end
    end
end
function P135(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 3 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 67 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 68 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 69 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 70 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 71 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 72 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 65 then
            turn = 67
        else
            turn = turn + 1
        end
    end
end
function P134(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 3 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 67 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 68 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 69 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 70 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 71 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 72 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 65 then
            turn = 67
        else
            turn = turn + 1
        end
    end
end
function P125(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 3 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 67 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 68 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 69 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 70 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 71 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 72 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 65 then
            turn = 67
        else
            turn = turn + 1
        end
    end
end
function P124(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 3 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 67 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 68 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 69 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 70 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 71 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 72 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 65 then
            turn = 67
        else
            turn = turn + 1
        end
    end
end
function P123(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 3 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 45 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 46 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 47 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 48 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 49 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 50 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 51 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 52 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 53 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 54 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 55 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 56 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 57 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 58 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 59 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 60 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 61 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 62 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 63 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 64 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 65 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 66 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 67 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 68 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 69 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 70 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 71 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 72 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 65 then
            turn = 67
        else
            turn = turn + 1
        end
    end
end

function P45(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 2 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 45 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 46 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 47 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 48 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 49 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 50 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 43 then
            turn = 45
        else
            turn = turn + 1
        end
    end
end
function P35(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 2 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 45 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 46 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 47 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 48 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 49 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 50 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 43 then
            turn = 45
        else
            turn = turn + 1
        end
    end
end
function P34(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 2 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 45 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 46 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 47 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 48 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 49 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 50 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 43 then
            turn = 45
        else
            turn = turn + 1
        end
    end
end
function P25(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 2 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 45 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 46 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 47 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 48 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 49 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 50 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 43 then
            turn = 45
        else
            turn = turn + 1
        end
    end
end
function P24(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 2 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 45 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 46 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 47 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 48 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 49 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 50 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 43 then
            turn = 45
        else
            turn = turn + 1
        end
    end
end
function P23(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 2 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 45 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 46 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 47 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 48 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 49 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 50 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 43 then
            turn = 45
        else
            turn = turn + 1
        end
    end
end
function P15(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 2 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 45 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 46 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 47 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 48 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 49 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 50 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 43 then
            turn = 45
        else
            turn = turn + 1
        end
    end
end
function P14(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 2 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 45 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 46 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 47 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 48 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 49 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 50 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 43 then
            turn = 45
        else
            turn = turn + 1
        end
    end
end
function P13(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 2 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 45 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 46 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 47 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 48 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 49 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 50 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 43 then
            turn = 45
        else
            turn = turn + 1
        end
    end
end
function P12(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 2 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 23 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 24 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 25 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 26 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 27 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 28 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 29 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 30 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 31 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 32 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 33 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 34 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 35 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 36 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 37 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 38 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 39 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 40 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 41 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 42 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 43 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 44 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 45 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 46 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 47 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 48 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 49 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 50 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 43 then
            turn = 45
        else
            turn = turn + 1
        end
    end
end

function P5(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, -285, 428)       -- Player 5: 1st Card
        elseif turn == 1 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -275, 438)       -- Player 5: 2nd Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -255, 458)       -- Player 5: 4th Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -245, 468)       -- Player 5: 5th Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -235, 478)       -- Player 5: 6th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -225, 488)       -- Player 5: 7th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -243, 445)       -- Player 5: 2nd Card (Split H1)
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -280, 464)       -- Player 5: 2nd Card (Split H2)
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -223, 465)       -- Player 5: 4th Card (Split H1)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -213, 475)       -- Player 5: 5th Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -203, 485)       -- Player 5: 6th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -193, 495)       -- Player 5: 7th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -233, 455)       -- Player 5: 3rd Card (Double) (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Split H2)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -260, 484)       -- Player 5: 4th Card (Split H2)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -250, 494)       -- Player 5: 5th Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -240, 504)       -- Player 5: 6th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -230, 514)       -- Player 5: 7th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -270, 474)       -- Player 5: 3rd Card (Double) (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -265, 448)       -- Player 5: 3rd Card (Double)
        elseif turn == 23 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 24 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 25 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 26 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 27 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 28 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 21 then
            turn = 23
        else
            turn = turn + 1
        end
    end
end
function P4(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, -165, 325)       -- Player 4: 1st Card
        elseif turn == 1 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -155, 335)       -- Player 4: 2nd Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -135, 355)       -- Player 4: 4th Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -125, 365)       -- Player 4: 5th Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -115, 375)       -- Player 4: 6th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -105, 385)       -- Player 4: 7th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 335)       -- Player 4: 2nd Card (Split H1)
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -172, 355)       -- Player 4: 2nd Card (Split H2)
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -112, 355)       -- Player 4: 4th Card (Split H1)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -102, 365)       -- Player 4: 5th Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -92, 375)       -- Player 4: 6th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -82, 385)       -- Player 4: 7th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 345)       -- Player 4: 3rd Card (Double) (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Split H2)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -152, 375)       -- Player 4: 4th Card (Split H2)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -142, 385)       -- Player 4: 5th Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -132, 395)       -- Player 4: 6th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -122, 405)       -- Player 4: 7th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -162, 365)       -- Player 4: 3rd Card (Double) (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -145, 345)       -- Player 4: 3rd Card (Double)
        elseif turn == 23 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 24 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 25 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 26 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 27 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 28 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 21 then
            turn = 23
        else
            turn = turn + 1
        end
    end
end
function P3(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 300)       -- Player 3: 1st Card
        elseif turn == 1 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 315)       -- Player 3: 2nd Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 30, 345)       -- Player 3: 4th Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 360)       -- Player 3: 5th Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 10, 375)       -- Player 3: 6th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 390)       -- Player 3: 7th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 324)       -- Player 3: 2nd Card (Split H1)
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 324)       -- Player 3: 2nd Card (Split H2)
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 55, 354)       -- Player 3: 4th Card (Split H1)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 369)       -- Player 3: 5th Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 35, 384)       -- Player 3: 6th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 25, 399)       -- Player 3: 7th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 45, 339)       -- Player 3: 3rd Card (Double) (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Split H2)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -47, 354)       -- Player 3: 4th Card (Split H2)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 369)       -- Player 3: 5th Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -27, 384)       -- Player 3: 6th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -17, 399)       -- Player 3: 7th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, -37, 339)       -- Player 3: 3rd Card (Double) (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 330)       -- Player 3: 3rd Card (Double)
        elseif turn == 23 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 24 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 25 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 26 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 27 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 28 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 21 then
            turn = 23
        else
            turn = turn + 1
        end
    end
end
function P2(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 325)       -- Player 2: 1st Card
        elseif turn == 1 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 335)       -- Player 2: 2nd Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 355)       -- Player 2: 4th Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 365)       -- Player 2: 5th Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 115, 375)       -- Player 2: 6th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 105, 385)       -- Player 2: 7th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 175, 360)       -- Player 2: 2nd Card (Split H1)
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 133, 340)       -- Player 2: 2nd Card (Split H2)
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 155, 380)       -- Player 2: 4th Card (Split H1)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 390)       -- Player 2: 5th Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 135, 400)       -- Player 2: 6th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 125, 410)       -- Player 2: 7th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 165, 370)       -- Player 2: 3rd Card (Double) (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Split H2)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 113, 360)       -- Player 2: 4th Card (Split H2)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 103, 370)       -- Player 2: 5th Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 93, 380)       -- Player 2: 6th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 83, 390)       -- Player 2: 7th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 123, 350)       -- Player 2: 3rd Card (Double) (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 145, 345)       -- Player 2: 3rd Card (Double)
        elseif turn == 23 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 24 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 25 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 26 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 27 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 28 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 21 then
            turn = 23
        else
            turn = turn + 1
        end
    end
end
function P1(cardName)
    if cardName and cardNames[cardName] then
        cardTexture = playerFrame:CreateTexture(nil, "OVERLAY")
        cardTexture:SetSize(32, 64)
        table.insert(drawnCards, cardTexture)  -- Store the texture in the table
        table.insert(dealtCards, cardNames[cardName])

        -- Position the card based on the turn count
        if turn == 0 then 
            cardTexture:SetPoint("BOTTOM", playerFrame, 296, 428)       -- Player 1: 1st Card
        elseif turn == 1 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 0, 500)         -- Dealer: 1st Card
        elseif turn == 2 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 286, 438)       -- Player 1: 2nd Card
        elseif turn == 3 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card
        elseif turn == 4 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 266, 458)       -- Player 1: 4th Card
        elseif turn == 5 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 256, 468)       -- Player 1: 5th Card
        elseif turn == 6 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 246, 478)       -- Player 1: 6th Card
        elseif turn == 7 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 236, 488)       -- Player 1: 7th Card
        elseif turn == 8 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 292, 464)       -- Player 1: 2nd Card (Split H1)
        elseif turn == 9 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 255, 445)       -- Player 1: 2nd Card (Split H2)
        elseif turn == 10 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Split H1)
        elseif turn == 11 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 272, 484)       -- Player 1: 4th Card (Split H1)
        elseif turn == 12 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 262, 494)       -- Player 1: 5th Card (Split H1)
        elseif turn == 13 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 252, 504)       -- Player 1: 6th Card (Split H1)
        elseif turn == 14 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 242, 514)       -- Player 1: 7th Card (Split H1)
        elseif turn == 15 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 282, 474)       -- Player 1: 3rd Card (Double) (Split H1)
        elseif turn == 16 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Split H2)
        elseif turn == 17 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 235, 465)       -- Player 1: 4th Card (Split H2)
        elseif turn == 18 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 225, 475)       -- Player 1: 5th Card (Split H2)
        elseif turn == 19 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 215, 485)       -- Player 1: 6th Card (Split H2)
        elseif turn == 20 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 205, 495)       -- Player 1: 7th Card (Split H2)
        elseif turn == 21 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 245, 455)       -- Player 1: 3rd Card (Double) (Split H2)
        elseif turn == 22 then
            cardTexture:SetPoint("BOTTOM", playerFrame, 276, 448)       -- Player 1: 3rd Card (Double)
        elseif turn == 23 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 20, 500)        -- Dealer: 2nd Card
        elseif turn == 24 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 40, 500)        -- Dealer: 3rd Card
        elseif turn == 25 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 60, 500)        -- Dealer: 4th Card
        elseif turn == 26 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 80, 500)        -- Dealer: 5th Card
        elseif turn == 27 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 100, 500)        -- Dealer: 6th Card
        elseif turn == 28 then
            cardTexture:SetSize(45, 90)
            cardTexture:SetPoint("BOTTOM", playerFrame, 120, 500)        -- Dealer: 7th Card
        end

        cardTexture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. cardName)
        cardTexture:SetDrawLayer("OVERLAY")

        if turn == 21 then
            turn = 23
        else
            turn = turn + 1
        end
    end
end









-- >> HANDLE CARDS / SOUNDS <<
-- >> HANDLE CARDS / SOUNDS <<
-- >> HANDLE CARDS / SOUNDS <<

function HandleCardsP12345(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player2CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P12345(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif turn == 5 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 7 or turn == 12 or turn == 13 or turn == 14 or turn == 15 or turn == 16 or turn == 31 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 31 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 17 or turn == 19 or turn == 20 or turn == 21 or turn == 22 or turn == 23 or turn == 24 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 31 -- Skip to Player 2: 3rd Card
                else
                    turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 31 -- Skip to Player 2: 3rd Card
                else
                    turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 31 -- Skip to Player 2: 3rd Card
                else
                    turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 31 -- Skip to Player 2: 3rd Card
                else
                    turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 31 -- Skip to Player 2: 3rd Card
                else
                    turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 31 -- Skip to Player 2: 3rd Card
                else
                    turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 31 -- Skip to Player 2: 3rd Card
                else
                    turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 31 -- Skip to Player 2: 3rd Card
                else
                    turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 31 -- Skip to Player 2: 3rd Card
                else
                    turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 31 -- Skip to Player 2: 3rd Card
                else
                    turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 23 or turn == 24 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 31 -- Skip to Player 2: 3rd Card
                else
                    turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 18 or turn == 25 or turn == 26 or turn == 27 or turn == 28 or turn == 29 or turn == 30 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 31 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 31 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 31 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 31 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 31 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 31 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 31 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 31 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 31 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 31 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 18 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 31 -- Skip to Player 2: 3rd Card
                    else
                        turn = 24 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 8 or turn == 32 or turn == 33 or turn == 34 or turn == 35 or turn == 36 or turn == 51 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 51 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 37 or turn == 39 or turn == 40 or turn == 41 or turn == 42 or turn == 43 or turn == 44 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 51 -- Skip to Player 3: 3rd Card
                else
                    turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 51 -- Skip to Player 3: 3rd Card
                else
                    turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 51 -- Skip to Player 3: 3rd Card
                else
                    turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 51 -- Skip to Player 3: 3rd Card
                else
                    turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 51 -- Skip to Player 3: 3rd Card
                else
                    turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 51 -- Skip to Player 3: 3rd Card
                else
                    turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 51 -- Skip to Player 3: 3rd Card
                else
                    turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 51 -- Skip to Player 3: 3rd Card
                else
                    turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 51 -- Skip to Player 3: 3rd Card
                else
                    turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 51 -- Skip to Player 3: 3rd Card
                else
                    turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 43 or turn == 44 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 51 -- Skip to Player 3: 3rd Card
                else
                    turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 38 or turn == 45 or turn == 46 or turn == 47 or turn == 48 or turn == 49 or turn == 50 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 51 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 51 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 51 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 51 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 51 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 51 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 51 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 51 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 51 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 51 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 38 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 51 -- Skip to Player 3: 3rd Card
                    else
                        turn = 44 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 9 or turn == 52 or turn == 53 or turn == 54 or turn == 55 or turn == 56 or turn == 71 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 71 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 57 or turn == 59 or turn == 60 or turn == 61 or turn == 62 or turn == 63 or turn == 64 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 71 -- Skip to Player 4: 3rd Card
                else
                    turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 71 -- Skip to Player 4: 3rd Card
                else
                    turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 71 -- Skip to Player 4: 3rd Card
                else
                    turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 71 -- Skip to Player 4: 3rd Card
                else
                    turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 71 -- Skip to Player 4: 3rd Card
                else
                    turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 71 -- Skip to Player 4: 3rd Card
                else
                    turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 71 -- Skip to Player 4: 3rd Card
                else
                    turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 71 -- Skip to Player 4: 3rd Card
                else
                    turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 71 -- Skip to Player 4: 3rd Card
                else
                    turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 71 -- Skip to Player 4: 3rd Card
                else
                    turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 63 or turn == 64 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 71 -- Skip to Player 4: 3rd Card
                else
                    turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 58 or turn == 65 or turn == 66 or turn == 67 or turn == 68 or turn == 69 or turn == 70 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 71 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 71 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 71 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 71 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 71 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 71 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 71 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 71 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 71 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 71 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 58 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 71 -- Skip to Player 4: 3rd Card
                    else
                        turn = 64 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 10 or turn == 72 or turn == 73 or turn == 74 or turn == 75 or turn == 76 or turn == 91 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 91 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
        elseif turn == 77 or turn == 79 or turn == 80 or turn == 81 or turn == 82 or turn == 83 or turn == 84 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 91 -- Skip to Player 5: 3rd Card
                else
                    turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 91 -- Skip to Player 5: 3rd Card
                else
                    turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 91 -- Skip to Player 5: 3rd Card
                else
                    turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 91 -- Skip to Player 5: 3rd Card
                else
                    turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 91 -- Skip to Player 5: 3rd Card
                else
                    turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 91 -- Skip to Player 5: 3rd Card
                else
                    turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 91 -- Skip to Player 5: 3rd Card
                else
                    turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 91 -- Skip to Player 5: 3rd Card
                else
                    turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 91 -- Skip to Player 5: 3rd Card
                else
                    turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 91 -- Skip to Player 5: 3rd Card
                else
                    turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 83 or turn == 84 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 91 -- Skip to Player 5: 3rd Card
                else
                    turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 78 or turn == 85 or turn == 86 or turn == 87 or turn == 88 or turn == 89 or turn == 90 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 91 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 91 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 91 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 91 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 91 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 91 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 91 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 91 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 91 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 91 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 78 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 91 -- Skip to Player 5: 3rd Card
                    else
                        turn = 84 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 11 or turn == 92 or turn == 93 or turn == 94 or turn == 95 or turn == 96 or turn == 111 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 111 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 11 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                            if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                                if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                                    turn = 111 -- Skip to Dealer: 2nd Card
                                else
                                    turn = 91 -- Skip to Player 5: 3rd Card
                                end
                            else
                                turn = 71 -- Skip to Player 4: 3rd Card
                            end
                        else
                            turn = 51 -- Skip to Player 3: 3rd Card
                        end
                    else
                        turn = 31 -- Skip to Player 2: 3rd Card
                    end
                else
                    turn = 11 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 97 or turn == 99 or turn == 100 or turn == 101 or turn == 102 or turn == 103 or turn == 104 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 111 -- Skip to Dealer: 2nd Card
                else
                    turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 111 -- Skip to Dealer: 2nd Card
                else
                    turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 111 -- Skip to Dealer: 2nd Card
                else
                    turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 111 -- Skip to Dealer: 2nd Card
                else
                    turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 111 -- Skip to Dealer: 2nd Card
                else
                    turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 111 -- Skip to Dealer: 2nd Card
                else
                    turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 111 -- Skip to Dealer: 2nd Card
                else
                    turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 111 -- Skip to Dealer: 2nd Card
                else
                    turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 111 -- Skip to Dealer: 2nd Card
                else
                    turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 111 -- Skip to Dealer: 2nd Card
                else
                    turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 103 or turn == 104 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 111 -- Skip to Dealer: 2nd Card
                else
                    turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 98 or turn == 105 or turn == 106 or turn == 107 or turn == 108 or turn == 109 or turn == 110 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 111 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 111 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 111 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 111 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 111 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 111 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 111 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 111 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 111 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 111 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 98 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 111 -- Skip to Dealer: 2nd Card
                    else
                        turn = 104 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 6 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 112 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()

            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end

function HandleCardsP2345(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player2CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P2345(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 6 or turn == 10 or turn == 11 or turn == 12 or turn == 13 or turn == 14 or turn == 29 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 15 or turn == 17 or turn == 18 or turn == 19 or turn == 20 or turn == 21 or turn == 22 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 21 or turn == 22 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 16 or turn == 23 or turn == 24 or turn == 25 or turn == 26 or turn == 27 or turn == 28 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 16 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 29 -- Skip to Player 3: 3rd Card
                    else
                        turn = 22 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 7 or turn == 30 or turn == 31 or turn == 32 or turn == 33 or turn == 34 or turn == 49 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 35 or turn == 37 or turn == 38 or turn == 39 or turn == 40 or turn == 41 or turn == 42 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 41 or turn == 42 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 36 or turn == 43 or turn == 44 or turn == 45 or turn == 46 or turn == 47 or turn == 48 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 36 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 49 -- Skip to Player 4: 3rd Card
                    else
                        turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 8 or turn == 50 or turn == 51 or turn == 52 or turn == 53 or turn == 54 or turn == 69 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
        elseif turn == 55 or turn == 57 or turn == 58 or turn == 59 or turn == 60 or turn == 61 or turn == 62 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 61 or turn == 62 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 56 or turn == 63 or turn == 64 or turn == 65 or turn == 66 or turn == 67 or turn == 68 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 56 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 69 -- Skip to Player 5: 3rd Card
                    else
                        turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 9 or turn == 70 or turn == 71 or turn == 72 or turn == 73 or turn == 74 or turn == 89 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 9 then
                if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                            if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                                turn = 89 -- Skip to Dealer: 2nd Card
                            else
                                turn = 69 -- Skip to Player 5: 3rd Card
                            end
                        else
                            turn = 49 -- Skip to Player 4: 3rd Card
                        end
                    else
                        turn = 29 -- Skip to Player 3: 3rd Card
                    end
                else
                    turn = 9 -- Skip to Player 2: 3rd Card
                end
            end
        elseif turn == 75 or turn == 77 or turn == 78 or turn == 79 or turn == 80 or turn == 81 or turn == 82 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 81 or turn == 82 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 76 or turn == 83 or turn == 84 or turn == 85 or turn == 86 or turn == 87 or turn == 88 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 76 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 89 -- Skip to Dealer: 2nd Card
                    else
                        turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 5 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 90 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP1345(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P1345(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 6 or turn == 10 or turn == 11 or turn == 12 or turn == 13 or turn == 14 or turn == 29 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 15 or turn == 17 or turn == 18 or turn == 19 or turn == 20 or turn == 21 or turn == 22 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 21 or turn == 22 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 3: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 16 or turn == 23 or turn == 24 or turn == 25 or turn == 26 or turn == 27 or turn == 28 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 16 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 29 -- Skip to Player 3: 3rd Card
                    else
                        turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 7 or turn == 30 or turn == 31 or turn == 32 or turn == 33 or turn == 34 or turn == 49 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 35 or turn == 37 or turn == 38 or turn == 39 or turn == 40 or turn == 41 or turn == 42 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 41 or turn == 42 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 36 or turn == 43 or turn == 44 or turn == 45 or turn == 46 or turn == 47 or turn == 48 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 36 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 49 -- Skip to Player 4: 3rd Card
                    else
                        turn = 42 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 8 or turn == 50 or turn == 51 or turn == 52 or turn == 53 or turn == 54 or turn == 69 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
        elseif turn == 55 or turn == 57 or turn == 58 or turn == 59 or turn == 60 or turn == 61 or turn == 62 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 61 or turn == 62 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 56 or turn == 63 or turn == 64 or turn == 65 or turn == 66 or turn == 67 or turn == 68 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 56 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 69 -- Skip to Player 5: 3rd Card
                    else
                        turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 9 or turn == 70 or turn == 71 or turn == 72 or turn == 73 or turn == 74 or turn == 89 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 9 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                            if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                                turn = 89 -- Skip to Dealer: 2nd Card
                            else
                                turn = 69 -- Skip to Player 5: 3rd Card
                            end
                        else
                            turn = 49 -- Skip to Player 4: 3rd Card
                        end
                    else
                        turn = 29 -- Skip to Player 3: 3rd Card
                    end
                else
                    turn = 9 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 75 or turn == 77 or turn == 78 or turn == 79 or turn == 80 or turn == 81 or turn == 82 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 81 or turn == 82 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 76 or turn == 83 or turn == 84 or turn == 85 or turn == 86 or turn == 87 or turn == 88 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 76 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 89 -- Skip to Dealer: 2nd Card
                    else
                        turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 5 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 90 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP1245(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player2CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P1245(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 6 or turn == 10 or turn == 11 or turn == 12 or turn == 13 or turn == 14 or turn == 29 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 15 or turn == 17 or turn == 18 or turn == 19 or turn == 20 or turn == 21 or turn == 22 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 21 or turn == 22 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 16 or turn == 23 or turn == 24 or turn == 25 or turn == 26 or turn == 27 or turn == 28 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 16 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 29 -- Skip to Player 2: 3rd Card
                    else
                        turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 7 or turn == 30 or turn == 31 or turn == 32 or turn == 33 or turn == 34 or turn == 49 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 49 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 35 or turn == 37 or turn == 38 or turn == 39 or turn == 40 or turn == 41 or turn == 42 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 41 or turn == 42 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 4: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 36 or turn == 43 or turn == 44 or turn == 45 or turn == 46 or turn == 47 or turn == 48 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 36 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 49 -- Skip to Player 4: 3rd Card
                    else
                        turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 8 or turn == 50 or turn == 51 or turn == 52 or turn == 53 or turn == 54 or turn == 69 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
        elseif turn == 55 or turn == 57 or turn == 58 or turn == 59 or turn == 60 or turn == 61 or turn == 62 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 61 or turn == 62 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 56 or turn == 63 or turn == 64 or turn == 65 or turn == 66 or turn == 67 or turn == 68 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 56 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 69 -- Skip to Player 5: 3rd Card
                    else
                        turn = 62 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 9 or turn == 70 or turn == 71 or turn == 72 or turn == 73 or turn == 74 or turn == 89 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 9 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                            if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                                turn = 89 -- Skip to Dealer: 2nd Card
                            else
                                turn = 69 -- Skip to Player 5: 3rd Card
                            end
                        else
                            turn = 49 -- Skip to Player 4: 3rd Card
                        end
                    else
                        turn = 29 -- Skip to Player 2: 3rd Card
                    end
                else
                    turn = 9 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 75 or turn == 77 or turn == 78 or turn == 79 or turn == 80 or turn == 81 or turn == 82 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 81 or turn == 82 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 76 or turn == 83 or turn == 84 or turn == 85 or turn == 86 or turn == 87 or turn == 88 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 76 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 89 -- Skip to Dealer: 2nd Card
                    else
                        turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 5 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 90 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP1235(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player2CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P1235(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 6 or turn == 10 or turn == 11 or turn == 12 or turn == 13 or turn == 14 or turn == 29 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 15 or turn == 17 or turn == 18 or turn == 19 or turn == 20 or turn == 21 or turn == 22 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 21 or turn == 22 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 16 or turn == 23 or turn == 24 or turn == 25 or turn == 26 or turn == 27 or turn == 28 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 16 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 29 -- Skip to Player 2: 3rd Card
                    else
                        turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 7 or turn == 30 or turn == 31 or turn == 32 or turn == 33 or turn == 34 or turn == 49 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 35 or turn == 37 or turn == 38 or turn == 39 or turn == 40 or turn == 41 or turn == 42 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 41 or turn == 42 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 36 or turn == 43 or turn == 44 or turn == 45 or turn == 46 or turn == 47 or turn == 48 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 36 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 49 -- Skip to Player 3: 3rd Card
                    else
                        turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 8 or turn == 50 or turn == 51 or turn == 52 or turn == 53 or turn == 54 or turn == 69 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 55 or turn == 57 or turn == 58 or turn == 59 or turn == 60 or turn == 61 or turn == 62 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 61 or turn == 62 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 5: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 56 or turn == 63 or turn == 64 or turn == 65 or turn == 66 or turn == 67 or turn == 68 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 56 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 69 -- Skip to Player 5: 3rd Card
                    else
                        turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 9 or turn == 70 or turn == 71 or turn == 72 or turn == 73 or turn == 74 or turn == 89 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 9 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                            if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                                turn = 89 -- Skip to Dealer: 2nd Card
                            else
                                turn = 69 -- Skip to Player 5: 3rd Card
                            end
                        else
                            turn = 49 -- Skip to Player 3: 3rd Card
                        end
                    else
                        turn = 29 -- Skip to Player 2: 3rd Card
                    end
                else
                    turn = 9 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 75 or turn == 77 or turn == 78 or turn == 79 or turn == 80 or turn == 81 or turn == 82 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 81 or turn == 82 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 76 or turn == 83 or turn == 84 or turn == 85 or turn == 86 or turn == 87 or turn == 88 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 76 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 89 -- Skip to Dealer: 2nd Card
                    else
                        turn = 82 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 5 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 90 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP1234(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player2CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P1234(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 6 or turn == 10 or turn == 11 or turn == 12 or turn == 13 or turn == 14 or turn == 29 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 15 or turn == 17 or turn == 18 or turn == 19 or turn == 20 or turn == 21 or turn == 22 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 21 or turn == 22 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 29 -- Skip to Player 2: 3rd Card
                else
                    turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 16 or turn == 23 or turn == 24 or turn == 25 or turn == 26 or turn == 27 or turn == 28 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 29 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 16 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 29 -- Skip to Player 2: 3rd Card
                    else
                        turn = 22 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 7 or turn == 30 or turn == 31 or turn == 32 or turn == 33 or turn == 34 or turn == 49 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 35 or turn == 37 or turn == 38 or turn == 39 or turn == 40 or turn == 41 or turn == 42 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 41 or turn == 42 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 49 -- Skip to Player 3: 3rd Card
                else
                    turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 36 or turn == 43 or turn == 44 or turn == 45 or turn == 46 or turn == 47 or turn == 48 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 49 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 36 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 49 -- Skip to Player 3: 3rd Card
                    else
                        turn = 42 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 8 or turn == 50 or turn == 51 or turn == 52 or turn == 53 or turn == 54 or turn == 69 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 69 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 55 or turn == 57 or turn == 58 or turn == 59 or turn == 60 or turn == 61 or turn == 62 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 4: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 4: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 4: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 4: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 4: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 4: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 4: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 4: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 4: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 4: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 61 or turn == 62 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 69 -- Skip to Player 4: 3rd Card
                else
                    turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 56 or turn == 63 or turn == 64 or turn == 65 or turn == 66 or turn == 67 or turn == 68 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 69 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 69 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 56 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 69 -- Skip to Player 4: 3rd Card
                    else
                        turn = 62 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 9 or turn == 70 or turn == 71 or turn == 72 or turn == 73 or turn == 74 or turn == 89 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
            if turn == 9 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                            if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                                turn = 89 -- Skip to Dealer: 2nd Card
                            else
                                turn = 69 -- Skip to Player 4: 3rd Card
                            end
                        else
                            turn = 49 -- Skip to Player 3: 3rd Card
                        end
                    else
                        turn = 29 -- Skip to Player 2: 3rd Card
                    end
                else
                    turn = 9 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 75 or turn == 77 or turn == 78 or turn == 79 or turn == 80 or turn == 81 or turn == 82 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 81 or turn == 82 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 89 -- Skip to Dealer: 2nd Card
                else
                    turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 76 or turn == 83 or turn == 84 or turn == 85 or turn == 86 or turn == 87 or turn == 88 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 89 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 76 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 89 -- Skip to Dealer: 2nd Card
                    else
                        turn = 82 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 5 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 90 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end

function HandleCardsP345(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player3CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P345(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 5 or turn == 8 or turn == 9 or turn == 10 or turn == 11 or turn == 12 or turn == 27 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 13 or turn == 15 or turn == 16 or turn == 17 or turn == 18 or turn == 19 or turn == 20 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 19 or turn == 20 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 14 or turn == 21 or turn == 22 or turn == 23 or turn == 24 or turn == 25 or turn == 26 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 14 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 27 -- Skip to Player 4: 3rd Card
                    else
                        turn = 20 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 6 or turn == 28 or turn == 29 or turn == 30 or turn == 31 or turn == 32 or turn == 47 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
        elseif turn == 33 or turn == 35 or turn == 36 or turn == 37 or turn == 38 or turn == 39 or turn == 40 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 39 or turn == 40 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 34 or turn == 41 or turn == 42 or turn == 43 or turn == 44 or turn == 45 or turn == 46 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 34 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 47 -- Skip to Player 5: 3rd Card
                    else
                        turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 7 or turn == 48 or turn == 49 or turn == 50 or turn == 51 or turn == 52 or turn == 67 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 7 then
                if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                            turn = 67 -- Skip to Dealer: 2nd Card
                        else
                            turn = 47 -- Skip to Player 5: 3rd Card
                        end
                    else
                        turn = 27 -- Skip to Player 4: 3rd Card
                    end
                else
                    turn = 7 -- Skip to Player 3: 3rd Card
                end
            end
        elseif turn == 53 or turn == 55 or turn == 56 or turn == 57 or turn == 58 or turn == 59 or turn == 60 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 59 or turn == 60 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 54 or turn == 61 or turn == 62 or turn == 63 or turn == 64 or turn == 65 or turn == 66 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 54 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 67 -- Skip to Dealer: 2nd Card
                    else
                        turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 68 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP245(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player2CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P245(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 5 or turn == 8 or turn == 9 or turn == 10 or turn == 11 or turn == 12 or turn == 27 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 13 or turn == 15 or turn == 16 or turn == 17 or turn == 18 or turn == 19 or turn == 20 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 19 or turn == 20 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 14 or turn == 21 or turn == 22 or turn == 23 or turn == 24 or turn == 25 or turn == 26 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 14 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 27 -- Skip to Player 4: 3rd Card
                    else
                        turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 6 or turn == 28 or turn == 29 or turn == 30 or turn == 31 or turn == 32 or turn == 47 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
        elseif turn == 33 or turn == 35 or turn == 36 or turn == 37 or turn == 38 or turn == 39 or turn == 40 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 39 or turn == 40 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 34 or turn == 41 or turn == 42 or turn == 43 or turn == 44 or turn == 45 or turn == 46 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 34 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 47 -- Skip to Player 5: 3rd Card
                    else
                        turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 7 or turn == 48 or turn == 49 or turn == 50 or turn == 51 or turn == 52 or turn == 67 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 7 then
                if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                            turn = 67 -- Skip to Dealer: 2nd Card
                        else
                            turn = 47 -- Skip to Player 5: 3rd Card
                        end
                    else
                        turn = 27 -- Skip to Player 4: 3rd Card
                    end
                else
                    turn = 7 -- Skip to Player 2: 3rd Card
                end
            end
        elseif turn == 53 or turn == 55 or turn == 56 or turn == 57 or turn == 58 or turn == 59 or turn == 60 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 59 or turn == 60 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 54 or turn == 61 or turn == 62 or turn == 63 or turn == 64 or turn == 65 or turn == 66 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 54 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 67 -- Skip to Dealer: 2nd Card
                    else
                        turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 68 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP235(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player2CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P235(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 5 or turn == 8 or turn == 9 or turn == 10 or turn == 11 or turn == 12 or turn == 27 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 13 or turn == 15 or turn == 16 or turn == 17 or turn == 18 or turn == 19 or turn == 20 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 19 or turn == 20 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 14 or turn == 21 or turn == 22 or turn == 23 or turn == 24 or turn == 25 or turn == 26 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 14 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 27 -- Skip to Player 3: 3rd Card
                    else
                        turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 6 or turn == 28 or turn == 29 or turn == 30 or turn == 31 or turn == 32 or turn == 47 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 33 or turn == 35 or turn == 36 or turn == 37 or turn == 38 or turn == 39 or turn == 40 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 39 or turn == 40 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 34 or turn == 41 or turn == 42 or turn == 43 or turn == 44 or turn == 45 or turn == 46 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 34 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 47 -- Skip to Player 5: 3rd Card
                    else
                        turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 7 or turn == 48 or turn == 49 or turn == 50 or turn == 51 or turn == 52 or turn == 67 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 7 then
                if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                            turn = 67 -- Skip to Dealer: 2nd Card
                        else
                            turn = 47 -- Skip to Player 5: 3rd Card
                        end
                    else
                        turn = 27 -- Skip to Player 3: 3rd Card
                    end
                else
                    turn = 7 -- Skip to Player 2: 3rd Card
                end
            end
        elseif turn == 53 or turn == 55 or turn == 56 or turn == 57 or turn == 58 or turn == 59 or turn == 60 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 59 or turn == 60 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 54 or turn == 61 or turn == 62 or turn == 63 or turn == 64 or turn == 65 or turn == 66 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 54 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 67 -- Skip to Dealer: 2nd Card
                    else
                        turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 68 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP234(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player2CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P234(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 5 or turn == 8 or turn == 9 or turn == 10 or turn == 11 or turn == 12 or turn == 27 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 13 or turn == 15 or turn == 16 or turn == 17 or turn == 18 or turn == 19 or turn == 20 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 19 or turn == 20 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 14 or turn == 21 or turn == 22 or turn == 23 or turn == 24 or turn == 25 or turn == 26 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 14 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 27 -- Skip to Player 3: 3rd Card
                    else
                        turn = 20 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 6 or turn == 28 or turn == 29 or turn == 30 or turn == 31 or turn == 32 or turn == 47 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 33 or turn == 35 or turn == 36 or turn == 37 or turn == 38 or turn == 39 or turn == 40 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 39 or turn == 40 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 34 or turn == 41 or turn == 42 or turn == 43 or turn == 44 or turn == 45 or turn == 46 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 34 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 47 -- Skip to Player 4: 3rd Card
                    else
                        turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 7 or turn == 48 or turn == 49 or turn == 50 or turn == 51 or turn == 52 or turn == 67 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
            if turn == 7 then
                if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                            turn = 67 -- Skip to Dealer: 2nd Card
                        else
                            turn = 47 -- Skip to Player 5: 3rd Card
                        end
                    else
                        turn = 27 -- Skip to Player 3: 3rd Card
                    end
                else
                    turn = 7 -- Skip to Player 2: 3rd Card
                end
            end
        elseif turn == 53 or turn == 55 or turn == 56 or turn == 57 or turn == 58 or turn == 59 or turn == 60 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 59 or turn == 60 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 54 or turn == 61 or turn == 62 or turn == 63 or turn == 64 or turn == 65 or turn == 66 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 54 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 67 -- Skip to Dealer: 2nd Card
                    else
                        turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 68 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP145(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P145(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 5 or turn == 8 or turn == 9 or turn == 10 or turn == 11 or turn == 12 or turn == 27 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 13 or turn == 15 or turn == 16 or turn == 17 or turn == 18 or turn == 19 or turn == 20 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 19 or turn == 20 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 4: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 14 or turn == 21 or turn == 22 or turn == 23 or turn == 24 or turn == 25 or turn == 26 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 14 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 27 -- Skip to Player 4: 3rd Card
                    else
                        turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 6 or turn == 28 or turn == 29 or turn == 30 or turn == 31 or turn == 32 or turn == 47 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
        elseif turn == 33 or turn == 35 or turn == 36 or turn == 37 or turn == 38 or turn == 39 or turn == 40 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 39 or turn == 40 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 34 or turn == 41 or turn == 42 or turn == 43 or turn == 44 or turn == 45 or turn == 46 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 34 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 47 -- Skip to Player 5: 3rd Card
                    else
                        turn = 40 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 7 or turn == 48 or turn == 49 or turn == 50 or turn == 51 or turn == 52 or turn == 67 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 7 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                            turn = 67 -- Skip to Dealer: 2nd Card
                        else
                            turn = 47 -- Skip to Player 5: 3rd Card
                        end
                    else
                        turn = 27 -- Skip to Player 4: 3rd Card
                    end
                else
                    turn = 7 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 53 or turn == 55 or turn == 56 or turn == 57 or turn == 58 or turn == 59 or turn == 60 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 59 or turn == 60 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 54 or turn == 61 or turn == 62 or turn == 63 or turn == 64 or turn == 65 or turn == 66 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 54 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 67 -- Skip to Dealer: 2nd Card
                    else
                        turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 68 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP135(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P135(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 5 or turn == 8 or turn == 9 or turn == 10 or turn == 11 or turn == 12 or turn == 27 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 13 or turn == 15 or turn == 16 or turn == 17 or turn == 18 or turn == 19 or turn == 20 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 19 or turn == 20 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 14 or turn == 21 or turn == 22 or turn == 23 or turn == 24 or turn == 25 or turn == 26 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 14 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 27 -- Skip to Player 3: 3rd Card
                    else
                        turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 6 or turn == 28 or turn == 29 or turn == 30 or turn == 31 or turn == 32 or turn == 47 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 33 or turn == 35 or turn == 36 or turn == 37 or turn == 38 or turn == 39 or turn == 40 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 39 or turn == 40 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 34 or turn == 41 or turn == 42 or turn == 43 or turn == 44 or turn == 45 or turn == 46 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 34 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 47 -- Skip to Player 5: 3rd Card
                    else
                        turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 7 or turn == 48 or turn == 49 or turn == 50 or turn == 51 or turn == 52 or turn == 67 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 7 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                            turn = 67 -- Skip to Dealer: 2nd Card
                        else
                            turn = 47 -- Skip to Player 5: 3rd Card
                        end
                    else
                        turn = 27 -- Skip to Player 3: 3rd Card
                    end
                else
                    turn = 7 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 53 or turn == 55 or turn == 56 or turn == 57 or turn == 58 or turn == 59 or turn == 60 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 59 or turn == 60 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 54 or turn == 61 or turn == 62 or turn == 63 or turn == 64 or turn == 65 or turn == 66 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 54 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 67 -- Skip to Dealer: 2nd Card
                    else
                        turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 68 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP134(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P134(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 5 or turn == 8 or turn == 9 or turn == 10 or turn == 11 or turn == 12 or turn == 27 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 13 or turn == 15 or turn == 16 or turn == 17 or turn == 18 or turn == 19 or turn == 20 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 19 or turn == 20 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 3: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 14 or turn == 21 or turn == 22 or turn == 23 or turn == 24 or turn == 25 or turn == 26 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 14 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 27 -- Skip to Player 3: 3rd Card
                    else
                        turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 6 or turn == 28 or turn == 29 or turn == 30 or turn == 31 or turn == 32 or turn == 47 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 33 or turn == 35 or turn == 36 or turn == 37 or turn == 38 or turn == 39 or turn == 40 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 39 or turn == 40 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 34 or turn == 41 or turn == 42 or turn == 43 or turn == 44 or turn == 45 or turn == 46 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 34 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 47 -- Skip to Player 4: 3rd Card
                    else
                        turn = 40 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 7 or turn == 48 or turn == 49 or turn == 50 or turn == 51 or turn == 52 or turn == 67 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
            if turn == 7 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                            turn = 67 -- Skip to Dealer: 2nd Card
                        else
                            turn = 47 -- Skip to Player 4: 3rd Card
                        end
                    else
                        turn = 27 -- Skip to Player 3: 3rd Card
                    end
                else
                    turn = 7 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 53 or turn == 55 or turn == 56 or turn == 57 or turn == 58 or turn == 59 or turn == 60 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 59 or turn == 60 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 54 or turn == 61 or turn == 62 or turn == 63 or turn == 64 or turn == 65 or turn == 66 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 54 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 67 -- Skip to Dealer: 2nd Card
                    else
                        turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 68 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP125(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player2CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P125(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 5 or turn == 8 or turn == 9 or turn == 10 or turn == 11 or turn == 12 or turn == 27 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 13 or turn == 15 or turn == 16 or turn == 17 or turn == 18 or turn == 19 or turn == 20 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 19 or turn == 20 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 14 or turn == 21 or turn == 22 or turn == 23 or turn == 24 or turn == 25 or turn == 26 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 14 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 27 -- Skip to Player 2: 3rd Card
                    else
                        turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 6 or turn == 28 or turn == 29 or turn == 30 or turn == 31 or turn == 32 or turn == 47 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 33 or turn == 35 or turn == 36 or turn == 37 or turn == 38 or turn == 39 or turn == 40 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 39 or turn == 40 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 5: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 34 or turn == 41 or turn == 42 or turn == 43 or turn == 44 or turn == 45 or turn == 46 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 34 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 47 -- Skip to Player 5: 3rd Card
                    else
                        turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 7 or turn == 48 or turn == 49 or turn == 50 or turn == 51 or turn == 52 or turn == 67 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 7 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                            turn = 67 -- Skip to Dealer: 2nd Card
                        else
                            turn = 47 -- Skip to Player 5: 3rd Card
                        end
                    else
                        turn = 27 -- Skip to Player 2: 3rd Card
                    end
                else
                    turn = 7 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 53 or turn == 55 or turn == 56 or turn == 57 or turn == 58 or turn == 59 or turn == 60 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 59 or turn == 60 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 54 or turn == 61 or turn == 62 or turn == 63 or turn == 64 or turn == 65 or turn == 66 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 54 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 67 -- Skip to Dealer: 2nd Card
                    else
                        turn = 60 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 68 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP124(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player2CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P124(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 5 or turn == 8 or turn == 9 or turn == 10 or turn == 11 or turn == 12 or turn == 27 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 13 or turn == 15 or turn == 16 or turn == 17 or turn == 18 or turn == 19 or turn == 20 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 19 or turn == 20 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 14 or turn == 21 or turn == 22 or turn == 23 or turn == 24 or turn == 25 or turn == 26 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 14 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 27 -- Skip to Player 2: 3rd Card
                    else
                        turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 6 or turn == 28 or turn == 29 or turn == 30 or turn == 31 or turn == 32 or turn == 47 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 33 or turn == 35 or turn == 36 or turn == 37 or turn == 38 or turn == 39 or turn == 40 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 39 or turn == 40 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 4: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 34 or turn == 41 or turn == 42 or turn == 43 or turn == 44 or turn == 45 or turn == 46 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 34 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 47 -- Skip to Player 4: 3rd Card
                    else
                        turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 7 or turn == 48 or turn == 49 or turn == 50 or turn == 51 or turn == 52 or turn == 67 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
            if turn == 7 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                            turn = 67 -- Skip to Dealer: 2nd Card
                        else
                            turn = 47 -- Skip to Player 4: 3rd Card
                        end
                    else
                        turn = 27 -- Skip to Player 2: 3rd Card
                    end
                else
                    turn = 7 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 53 or turn == 55 or turn == 56 or turn == 57 or turn == 58 or turn == 59 or turn == 60 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 59 or turn == 60 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 54 or turn == 61 or turn == 62 or turn == 63 or turn == 64 or turn == 65 or turn == 66 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 54 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 67 -- Skip to Dealer: 2nd Card
                    else
                        turn = 60 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 68 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP123(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player2CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P123(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 5 or turn == 8 or turn == 9 or turn == 10 or turn == 11 or turn == 12 or turn == 27 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 13 or turn == 15 or turn == 16 or turn == 17 or turn == 18 or turn == 19 or turn == 20 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 19 or turn == 20 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 27 -- Skip to Player 2: 3rd Card
                else
                    turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 14 or turn == 21 or turn == 22 or turn == 23 or turn == 24 or turn == 25 or turn == 26 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 27 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 14 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 27 -- Skip to Player 2: 3rd Card
                    else
                        turn = 20 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 6 or turn == 28 or turn == 29 or turn == 30 or turn == 31 or turn == 32 or turn == 47 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 33 or turn == 35 or turn == 36 or turn == 37 or turn == 38 or turn == 39 or turn == 40 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 3: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 3: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 3: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 3: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 3: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 3: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 3: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 3: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 3: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 3: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 39 or turn == 40 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 47 -- Skip to Player 3: 3rd Card
                else
                    turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 34 or turn == 41 or turn == 42 or turn == 43 or turn == 44 or turn == 45 or turn == 46 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 47 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 47 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 34 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 47 -- Skip to Player 3: 3rd Card
                    else
                        turn = 40 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 7 or turn == 48 or turn == 49 or turn == 50 or turn == 51 or turn == 52 or turn == 67 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
            if turn == 7 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                        if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                            turn = 67 -- Skip to Dealer: 2nd Card
                        else
                            turn = 47 -- Skip to Player 3: 3rd Card
                        end
                    else
                        turn = 27 -- Skip to Player 2: 3rd Card
                    end
                else
                    turn = 7 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 53 or turn == 55 or turn == 56 or turn == 57 or turn == 58 or turn == 59 or turn == 60 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 59 or turn == 60 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 67 -- Skip to Dealer: 2nd Card
                else
                    turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 54 or turn == 61 or turn == 62 or turn == 63 or turn == 64 or turn == 65 or turn == 66 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 67 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 54 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 67 -- Skip to Dealer: 2nd Card
                    else
                        turn = 60 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 4 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 68 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end

function HandleCardsP45(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player4CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P45(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 4 or turn == 6 or turn == 7 or turn == 8 or turn == 9 or turn == 10 or turn == 25 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
        elseif turn == 11 or turn == 13 or turn == 14 or turn == 15 or turn == 16 or turn == 17 or turn == 18 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 4 :3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 17 or turn == 18 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 12 or turn == 19 or turn == 20 or turn == 21 or turn == 22 or turn == 23 or turn == 24 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 12 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 25 -- Skip to Player 5: 3rd Card
                    else
                        turn = 18 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 5 or turn == 26 or turn == 27 or turn == 28 or turn == 29 or turn == 30 or turn == 45 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 5 then
                if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 25 -- Skip to Player 5: 3rd Card
                    end
                else
                    turn = 5 -- Skip to Player 4: 3rd Card
                end
            end
        elseif turn == 31 or turn == 33 or turn == 34 or turn == 35 or turn == 36 or turn == 37 or turn == 38 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 37 or turn == 38 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 32 or turn == 39 or turn == 40 or turn == 41 or turn == 42 or turn == 43 or turn == 44 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 32 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 46 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP35(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player3CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P35(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 4 or turn == 6 or turn == 7 or turn == 8 or turn == 9 or turn == 10 or turn == 25 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 11 or turn == 13 or turn == 14 or turn == 15 or turn == 16 or turn == 17 or turn == 18 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 3 :3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 17 or turn == 18 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 12 or turn == 19 or turn == 20 or turn == 21 or turn == 22 or turn == 23 or turn == 24 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 12 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 25 -- Skip to Player 5: 3rd Card
                    else
                        turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 5 or turn == 26 or turn == 27 or turn == 28 or turn == 29 or turn == 30 or turn == 45 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 5 then
                if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 25 -- Skip to Player 5: 3rd Card
                    end
                else
                    turn = 5 -- Skip to Player 3: 3rd Card
                end
            end
        elseif turn == 31 or turn == 33 or turn == 34 or turn == 35 or turn == 36 or turn == 37 or turn == 38 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 37 or turn == 38 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 32 or turn == 39 or turn == 40 or turn == 41 or turn == 42 or turn == 43 or turn == 44 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 32 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 46 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP34(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player3CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P34(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 4 or turn == 6 or turn == 7 or turn == 8 or turn == 9 or turn == 10 or turn == 25 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 11 or turn == 13 or turn == 14 or turn == 15 or turn == 16 or turn == 17 or turn == 18 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 3 :3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 17 or turn == 18 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 12 or turn == 19 or turn == 20 or turn == 21 or turn == 22 or turn == 23 or turn == 24 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 12 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 25 -- Skip to Player 4: 3rd Card
                    else
                        turn = 18 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 5 or turn == 26 or turn == 27 or turn == 28 or turn == 29 or turn == 30 or turn == 45 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
            if turn == 5 then
                if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 25 -- Skip to Player 4: 3rd Card
                    end
                else
                    turn = 5 -- Skip to Player 3: 3rd Card
                end
            end
        elseif turn == 31 or turn == 33 or turn == 34 or turn == 35 or turn == 36 or turn == 37 or turn == 38 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 37 or turn == 38 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 32 or turn == 39 or turn == 40 or turn == 41 or turn == 42 or turn == 43 or turn == 44 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 32 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 46 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP25(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player2CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P25(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 4 or turn == 6 or turn == 7 or turn == 8 or turn == 9 or turn == 10 or turn == 25 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 11 or turn == 13 or turn == 14 or turn == 15 or turn == 16 or turn == 17 or turn == 18 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 2 :3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 17 or turn == 18 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 12 or turn == 19 or turn == 20 or turn == 21 or turn == 22 or turn == 23 or turn == 24 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 12 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 25 -- Skip to Player 5: 3rd Card
                    else
                        turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 5 or turn == 26 or turn == 27 or turn == 28 or turn == 29 or turn == 30 or turn == 45 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 5 then
                if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 25 -- Skip to Player 5: 3rd Card
                    end
                else
                    turn = 5 -- Skip to Player 2: 3rd Card
                end
            end
        elseif turn == 31 or turn == 33 or turn == 34 or turn == 35 or turn == 36 or turn == 37 or turn == 38 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 37 or turn == 38 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 32 or turn == 39 or turn == 40 or turn == 41 or turn == 42 or turn == 43 or turn == 44 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 32 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 46 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP24(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player2CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P24(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 4 or turn == 6 or turn == 7 or turn == 8 or turn == 9 or turn == 10 or turn == 25 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 11 or turn == 13 or turn == 14 or turn == 15 or turn == 16 or turn == 17 or turn == 18 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 2 :3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 17 or turn == 18 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 12 or turn == 19 or turn == 20 or turn == 21 or turn == 22 or turn == 23 or turn == 24 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 12 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 25 -- Skip to Player 4: 3rd Card
                    else
                        turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 5 or turn == 26 or turn == 27 or turn == 28 or turn == 29 or turn == 30 or turn == 45 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
            if turn == 5 then
                if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 25 -- Skip to Player 4: 3rd Card
                    end
                else
                    turn = 5 -- Skip to Player 2: 3rd Card
                end
            end
        elseif turn == 31 or turn == 33 or turn == 34 or turn == 35 or turn == 36 or turn == 37 or turn == 38 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 37 or turn == 38 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 32 or turn == 39 or turn == 40 or turn == 41 or turn == 42 or turn == 43 or turn == 44 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 32 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 46 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP23(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player2CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P23(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 4 or turn == 6 or turn == 7 or turn == 8 or turn == 9 or turn == 10 or turn == 25 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 11 or turn == 13 or turn == 14 or turn == 15 or turn == 16 or turn == 17 or turn == 18 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 2 :3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 17 or turn == 18 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 12 or turn == 19 or turn == 20 or turn == 21 or turn == 22 or turn == 23 or turn == 24 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 12 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 25 -- Skip to Player 3: 3rd Card
                    else
                        turn = 18 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 5 or turn == 26 or turn == 27 or turn == 28 or turn == 29 or turn == 30 or turn == 45 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
            if turn == 5 then
                if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 25 -- Skip to Player 3: 3rd Card
                    end
                else
                    turn = 5 -- Skip to Player 2: 3rd Card
                end
            end
        elseif turn == 31 or turn == 33 or turn == 34 or turn == 35 or turn == 36 or turn == 37 or turn == 38 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 37 or turn == 38 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 32 or turn == 39 or turn == 40 or turn == 41 or turn == 42 or turn == 43 or turn == 44 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 32 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 46 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP15(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P15(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 4 or turn == 6 or turn == 7 or turn == 8 or turn == 9 or turn == 10 or turn == 25 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 11 or turn == 13 or turn == 14 or turn == 15 or turn == 16 or turn == 17 or turn == 18 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 1 :3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 17 or turn == 18 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 5: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 12 or turn == 19 or turn == 20 or turn == 21 or turn == 22 or turn == 23 or turn == 24 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 5: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 12 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 25 -- Skip to Player 5: 3rd Card
                    else
                        turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 5 or turn == 26 or turn == 27 or turn == 28 or turn == 29 or turn == 30 or turn == 45 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[94])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
            if turn == 5 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 25 -- Skip to Player 5: 3rd Card
                    end
                else
                    turn = 5 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 31 or turn == 33 or turn == 34 or turn == 35 or turn == 36 or turn == 37 or turn == 38 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 37 or turn == 38 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                end
            end
        elseif turn == 32 or turn == 39 or turn == 40 or turn == 41 or turn == 42 or turn == 43 or turn == 44 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 32 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 38 -- Skip to Player 5: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 46 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP14(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player4CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P14(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 4 or turn == 6 or turn == 7 or turn == 8 or turn == 9 or turn == 10 or turn == 25 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 11 or turn == 13 or turn == 14 or turn == 15 or turn == 16 or turn == 17 or turn == 18 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 1 :3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 17 or turn == 18 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 4: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 12 or turn == 19 or turn == 20 or turn == 21 or turn == 22 or turn == 23 or turn == 24 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 4: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 12 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 25 -- Skip to Player 4: 3rd Card
                    else
                        turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 5 or turn == 26 or turn == 27 or turn == 28 or turn == 29 or turn == 30 or turn == 45 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[80])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
            if turn == 5 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 25 -- Skip to Player 4: 3rd Card
                    end
                else
                    turn = 5 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 31 or turn == 33 or turn == 34 or turn == 35 or turn == 36 or turn == 37 or turn == 38 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 37 or turn == 38 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                end
            end
        elseif turn == 32 or turn == 39 or turn == 40 or turn == 41 or turn == 42 or turn == 43 or turn == 44 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 32 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 38 -- Skip to Player 4: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 46 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP13(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player3CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P13(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 4 or turn == 6 or turn == 7 or turn == 8 or turn == 9 or turn == 10 or turn == 25 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 11 or turn == 13 or turn == 14 or turn == 15 or turn == 16 or turn == 17 or turn == 18 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 1 :3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 17 or turn == 18 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 3: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 12 or turn == 19 or turn == 20 or turn == 21 or turn == 22 or turn == 23 or turn == 24 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 3: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 12 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 25 -- Skip to Player 3: 3rd Card
                    else
                        turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 5 or turn == 26 or turn == 27 or turn == 28 or turn == 29 or turn == 30 or turn == 45 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
            if turn == 5 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 25 -- Skip to Player 3: 3rd Card
                    end
                else
                    turn = 5 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 31 or turn == 33 or turn == 34 or turn == 35 or turn == 36 or turn == 37 or turn == 38 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 37 or turn == 38 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                end
            end
        elseif turn == 32 or turn == 39 or turn == 40 or turn == 41 or turn == 42 or turn == 43 or turn == 44 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 32 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 38 -- Skip to Player 3: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 46 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP12(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.player2CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P12(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 4 or turn == 6 or turn == 7 or turn == 8 or turn == 9 or turn == 10 or turn == 25 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 11 or turn == 13 or turn == 14 or turn == 15 or turn == 16 or turn == 17 or turn == 18 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 2: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 2: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 2: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 2: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 2: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 2: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 2: 3rd Card
                else
                    turn = 18 -- Skip to Player 1 :3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 2: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 2: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 2: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 17 or turn == 18 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 25 -- Skip to Player 2: 3rd Card
                else
                    turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                end
            end
        elseif turn == 12 or turn == 19 or turn == 20 or turn == 21 or turn == 22 or turn == 23 or turn == 24 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 25 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 25 -- Skip to Player 2: 3rd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 12 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 25 -- Skip to Player 2: 3rd Card
                    else
                        turn = 18 -- Skip to Player 1: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 5 or turn == 26 or turn == 27 or turn == 28 or turn == 29 or turn == 30 or turn == 45 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
            if turn == 5 then
                if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 25 -- Skip to Player 2: 3rd Card
                    end
                else
                    turn = 5 -- Skip to Player 1: 3rd Card
                end
            end
        elseif turn == 31 or turn == 33 or turn == 34 or turn == 35 or turn == 36 or turn == 37 or turn == 38 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 37 or turn == 38 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 45 -- Skip to Dealer: 2nd Card
                else
                    turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                end
            end
        elseif turn == 32 or turn == 39 or turn == 40 or turn == 41 or turn == 42 or turn == 43 or turn == 44 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 45 -- Skip to Dealer: 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 32 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 45 -- Skip to Dealer: 2nd Card
                    else
                        turn = 38 -- Skip to Player 2: 3rd Card (Hand 2)
                    end
                end
            end
        end
    elseif turn == 3 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 46 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end

function HandleCardsP5(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player5CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P5(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player5CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player5CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player5CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player5CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player5CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player5CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player5CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player5CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player5CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player5CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName5) and string.find(message, "has") then
        if turn == 3 or turn == 4 or turn == 5 or turn == 6 or turn == 7 or turn == 8 or turn == 23 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player5CardTotalText:SetText("Blackjack")
                playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5CardTotalText:SetText("21")
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player5CardTotalText:SetText("22")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player5CardTotalText:SetText("23")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player5CardTotalText:SetText("24")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player5CardTotalText:SetText("25")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player5CardTotalText:SetText("26")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player5CardTotalText:SetText("27")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player5CardTotalText:SetText("28")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player5CardTotalText:SetText("29")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player5CardTotalText:SetText("30")
                playerFrame.player5CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5CardTotalText:SetText("13")
            end
        elseif turn == 9 or turn == 11 or turn == 12 or turn == 13 or turn == 14 or turn == 15 or turn == 16 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand1CardTotalText:SetText("21")
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand1CardTotalText:SetText("22")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand1CardTotalText:SetText("23")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand1CardTotalText:SetText("24")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand1CardTotalText:SetText("25")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand1CardTotalText:SetText("26")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand1CardTotalText:SetText("27")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand1CardTotalText:SetText("28")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand1CardTotalText:SetText("29")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand1CardTotalText:SetText("30")
                playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand1CardTotalText:SetText("13")
            elseif turn == 15 or turn == 16 then
                if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                end
            end
        elseif turn == 10 or turn == 17 or turn == 18 or turn == 19 or turn == 20 or turn == 21 or turn == 23 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player5SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player5SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player5SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player5SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player5SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player5SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player5SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player5SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player5SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player5SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player5SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player5SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player5SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player5SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player5SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player5SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player5SplitHand2CardTotalText:SetText("21")
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player5SplitHand2CardTotalText:SetText("22")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player5SplitHand2CardTotalText:SetText("23")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player5SplitHand2CardTotalText:SetText("24")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player5SplitHand2CardTotalText:SetText("25")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player5SplitHand2CardTotalText:SetText("26")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player5SplitHand2CardTotalText:SetText("27")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player5SplitHand2CardTotalText:SetText("28")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player5SplitHand2CardTotalText:SetText("29")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player5SplitHand2CardTotalText:SetText("30")
                playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player5SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player5SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player5SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player5SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player5SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player5SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player5SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player5SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player5SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player5SplitHand2CardTotalText:SetText("13")
            elseif turn == 10 then
                if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 23 -- Skip to Dealer 2nd Card
                    else
                        turn = 16 -- Skip to Player 5 3rd Card (Hand 2)
                    end
                end
            end
        end

    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 24 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP4(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player4CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P4(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player4CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player4CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player4CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player4CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player4CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player4CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player4CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player4CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player4CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player4CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName4) and string.find(message, "has") then
        if turn == 3 or turn == 4 or turn == 5 or turn == 6 or turn == 7 or turn == 8 or turn == 23 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player4CardTotalText:SetText("Blackjack")
                playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4CardTotalText:SetText("21")
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player4CardTotalText:SetText("22")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player4CardTotalText:SetText("23")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player4CardTotalText:SetText("24")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player4CardTotalText:SetText("25")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player4CardTotalText:SetText("26")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player4CardTotalText:SetText("27")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player4CardTotalText:SetText("28")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player4CardTotalText:SetText("29")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player4CardTotalText:SetText("30")
                playerFrame.player4CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4CardTotalText:SetText("13")
            end
        elseif turn == 9 or turn == 11 or turn == 12 or turn == 13 or turn == 14 or turn == 15 or turn == 16 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand1CardTotalText:SetText("21")
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand1CardTotalText:SetText("22")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand1CardTotalText:SetText("23")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand1CardTotalText:SetText("24")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand1CardTotalText:SetText("25")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand1CardTotalText:SetText("26")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand1CardTotalText:SetText("27")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand1CardTotalText:SetText("28")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand1CardTotalText:SetText("29")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand1CardTotalText:SetText("30")
                playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand1CardTotalText:SetText("13")
            elseif turn == 15 or turn == 16 then
                if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                end
            end
        elseif turn == 10 or turn == 17 or turn == 18 or turn == 19 or turn == 20 or turn == 21 or turn == 23 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player4SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player4SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player4SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player4SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player4SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player4SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player4SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player4SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player4SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player4SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player4SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player4SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player4SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player4SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player4SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player4SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player4SplitHand2CardTotalText:SetText("21")
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player4SplitHand2CardTotalText:SetText("22")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player4SplitHand2CardTotalText:SetText("23")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player4SplitHand2CardTotalText:SetText("24")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player4SplitHand2CardTotalText:SetText("25")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player4SplitHand2CardTotalText:SetText("26")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player4SplitHand2CardTotalText:SetText("27")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player4SplitHand2CardTotalText:SetText("28")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player4SplitHand2CardTotalText:SetText("29")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player4SplitHand2CardTotalText:SetText("30")
                playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player4SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player4SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player4SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player4SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player4SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player4SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player4SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player4SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player4SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player4SplitHand2CardTotalText:SetText("13")
            elseif turn == 10 then
                if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 23 -- Skip to Dealer 2nd Card
                    else
                        turn = 16 -- Skip to Player 4 3rd Card (Hand 2)
                    end
                end
            end
        end

    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 24 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP3(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player3CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P3(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player3CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player3CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player3CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player3CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player3CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player3CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player3CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player3CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player3CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player3CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName3) and string.find(message, "has") then
        if turn == 3 or turn == 4 or turn == 5 or turn == 6 or turn == 7 or turn == 8 or turn == 23 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[66])
                playerFrame.player3CardTotalText:SetText("Blackjack")
                playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3CardTotalText:SetText("21")
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player3CardTotalText:SetText("22")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player3CardTotalText:SetText("23")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player3CardTotalText:SetText("24")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player3CardTotalText:SetText("25")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player3CardTotalText:SetText("26")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player3CardTotalText:SetText("27")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player3CardTotalText:SetText("28")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player3CardTotalText:SetText("29")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player3CardTotalText:SetText("30")
                playerFrame.player3CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3CardTotalText:SetText("13")
            end
        elseif turn == 9 or turn == 11 or turn == 12 or turn == 13 or turn == 14 or turn == 15 or turn == 16 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand1CardTotalText:SetText("21")
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand1CardTotalText:SetText("22")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand1CardTotalText:SetText("23")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand1CardTotalText:SetText("24")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand1CardTotalText:SetText("25")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand1CardTotalText:SetText("26")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand1CardTotalText:SetText("27")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand1CardTotalText:SetText("28")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand1CardTotalText:SetText("29")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand1CardTotalText:SetText("30")
                playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand1CardTotalText:SetText("13")
            elseif turn == 15 or turn == 16 then
                if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                end
            end
        elseif turn == 10 or turn == 17 or turn == 18 or turn == 19 or turn == 20 or turn == 21 or turn == 23 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player3SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player3SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player3SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player3SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player3SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player3SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player3SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player3SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player3SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player3SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player3SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player3SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player3SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player3SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player3SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player3SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player3SplitHand2CardTotalText:SetText("21")
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player3SplitHand2CardTotalText:SetText("22")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player3SplitHand2CardTotalText:SetText("23")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player3SplitHand2CardTotalText:SetText("24")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player3SplitHand2CardTotalText:SetText("25")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player3SplitHand2CardTotalText:SetText("26")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player3SplitHand2CardTotalText:SetText("27")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player3SplitHand2CardTotalText:SetText("28")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player3SplitHand2CardTotalText:SetText("29")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player3SplitHand2CardTotalText:SetText("30")
                playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player3SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player3SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player3SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player3SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player3SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player3SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player3SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player3SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player3SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player3SplitHand2CardTotalText:SetText("13")
            elseif turn == 10 then
                if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 23 -- Skip to Dealer 2nd Card
                    else
                        turn = 16 -- Skip to Player 3 3rd Card (Hand 2)
                    end
                end
            end
        end

    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 24 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP2(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player2CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P2(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player2CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player2CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player2CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player2CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player2CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player2CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player2CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player2CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player2CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player2CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName2) and string.find(message, "has") then
        if turn == 3 or turn == 4 or turn == 5 or turn == 6 or turn == 7 or turn == 8 or turn == 23 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[52])
                playerFrame.player2CardTotalText:SetText("Blackjack")
                playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2CardTotalText:SetText("21")
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player2CardTotalText:SetText("22")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player2CardTotalText:SetText("23")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player2CardTotalText:SetText("24")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player2CardTotalText:SetText("25")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player2CardTotalText:SetText("26")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player2CardTotalText:SetText("27")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player2CardTotalText:SetText("28")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player2CardTotalText:SetText("29")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player2CardTotalText:SetText("30")
                playerFrame.player2CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2CardTotalText:SetText("13")
            end
        elseif turn == 9 or turn == 11 or turn == 12 or turn == 13 or turn == 14 or turn == 15 or turn == 16 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand1CardTotalText:SetText("21")
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand1CardTotalText:SetText("22")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand1CardTotalText:SetText("23")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand1CardTotalText:SetText("24")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand1CardTotalText:SetText("25")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand1CardTotalText:SetText("26")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand1CardTotalText:SetText("27")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand1CardTotalText:SetText("28")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand1CardTotalText:SetText("29")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand1CardTotalText:SetText("30")
                playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand1CardTotalText:SetText("13")
            elseif turn == 15 or turn == 16 then
                if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                end
            end
        elseif turn == 10 or turn == 17 or turn == 18 or turn == 19 or turn == 20 or turn == 21 or turn == 23 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player2SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player2SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player2SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player2SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player2SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player2SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player2SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player2SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player2SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player2SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player2SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player2SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player2SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player2SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player2SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player2SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player2SplitHand2CardTotalText:SetText("21")
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player2SplitHand2CardTotalText:SetText("22")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player2SplitHand2CardTotalText:SetText("23")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player2SplitHand2CardTotalText:SetText("24")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player2SplitHand2CardTotalText:SetText("25")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player2SplitHand2CardTotalText:SetText("26")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player2SplitHand2CardTotalText:SetText("27")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player2SplitHand2CardTotalText:SetText("28")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player2SplitHand2CardTotalText:SetText("29")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player2SplitHand2CardTotalText:SetText("30")
                playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player2SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player2SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player2SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player2SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player2SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player2SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player2SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player2SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player2SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player2SplitHand2CardTotalText:SetText("13")
            elseif turn == 10 then
                if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 23 -- Skip to Dealer 2nd Card
                    else
                        turn = 16 -- Skip to Player 2 3rd Card (Hand 2)
                    end
                end
            end
        end

    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 24 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end
function HandleCardsP1(message)
    -- Check if the message contains card names
    for cardName, cardFullName in pairs(cardNames) do
        playerFrame.player1CardTotalText:Show()
        playerFrame.dealerCardTotalText:Show()
        if string.find(message, cardFullName) then
            P1(cardName)
        end
    end

    _, _, number = string.find(message, "(%d+)")

    if turn == 1 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.player1CardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.player1CardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.player1CardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.player1CardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.player1CardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.player1CardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.player1CardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.player1CardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.player1CardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.player1CardTotalText:SetText("10")
        end
    elseif string.find(message, unitName1) and string.find(message, "has") then
        if turn == 3 or turn == 4 or turn == 5 or turn == 6 or turn == 7 or turn == 8 or turn == 23 and not string.find(message, "Hand 2") then
            if string.find(message, "Blackjack") then
                PlaySoundFile(soundFilePaths[38])
                playerFrame.player1CardTotalText:SetText("Blackjack")
                playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1CardTotalText:SetText("21")
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "22") then
                
                playerFrame.player1CardTotalText:SetText("22")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                
                playerFrame.player1CardTotalText:SetText("23")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                
                playerFrame.player1CardTotalText:SetText("24")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                
                playerFrame.player1CardTotalText:SetText("25")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                
                playerFrame.player1CardTotalText:SetText("26")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                
                playerFrame.player1CardTotalText:SetText("27")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                
                playerFrame.player1CardTotalText:SetText("28")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                
                playerFrame.player1CardTotalText:SetText("29")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                
                playerFrame.player1CardTotalText:SetText("30")
                playerFrame.player1CardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1CardTotalText:SetText("13")
            end
        elseif turn == 9 or turn == 11 or turn == 12 or turn == 13 or turn == 14 or turn == 15 or turn == 16 then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand1CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand1CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand1CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand1CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand1CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand1CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand1CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand1CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand1CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand1CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand1CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand1CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand1CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand1CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand1CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand1CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand1CardTotalText:SetText("21")
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                end
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand1CardTotalText:SetText("22")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                end
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand1CardTotalText:SetText("23")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                end
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand1CardTotalText:SetText("24")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                end
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand1CardTotalText:SetText("25")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                end
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand1CardTotalText:SetText("26")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                end
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand1CardTotalText:SetText("27")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                end
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand1CardTotalText:SetText("28")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                end
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand1CardTotalText:SetText("29")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                end
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand1CardTotalText:SetText("30")
                playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 0, 0)
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                end
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand1CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand1CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand1CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand1CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand1CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand1CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand1CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand1CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand1CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand1CardTotalText:SetText("13")
            elseif turn == 15 or turn == 16 then
                if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                    turn = 23 -- Skip to Dealer 2nd Card
                else
                    turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                end
            end
        elseif turn == 10 or turn == 17 or turn == 18 or turn == 19 or turn == 20 or turn == 21 or turn == 23 and string.find(message, "Hand 2") then
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.player1SplitHand2CardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.player1SplitHand2CardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.player1SplitHand2CardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.player1SplitHand2CardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.player1SplitHand2CardTotalText:SetText("6 or 16")
            elseif string.find(message, "7 or 17") then
                PlaySoundFile(soundFilePaths[28])
                playerFrame.player1SplitHand2CardTotalText:SetText("7 or 17")
            elseif string.find(message, "8 or 18") then
                PlaySoundFile(soundFilePaths[29])
                playerFrame.player1SplitHand2CardTotalText:SetText("8 or 18")
            elseif string.find(message, "9 or 19") then
                PlaySoundFile(soundFilePaths[30])
                playerFrame.player1SplitHand2CardTotalText:SetText("9 or 19")
            elseif string.find(message, "10 or 20") then
                PlaySoundFile(soundFilePaths[31])
                playerFrame.player1SplitHand2CardTotalText:SetText("10 or 20")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.player1SplitHand2CardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.player1SplitHand2CardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.player1SplitHand2CardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.player1SplitHand2CardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.player1SplitHand2CardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.player1SplitHand2CardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.player1SplitHand2CardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.player1SplitHand2CardTotalText:SetText("21")
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "22") then
                playerFrame.player1SplitHand2CardTotalText:SetText("22")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "23") then
                playerFrame.player1SplitHand2CardTotalText:SetText("23")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "24") then
                playerFrame.player1SplitHand2CardTotalText:SetText("24")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "25") then
                playerFrame.player1SplitHand2CardTotalText:SetText("25")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "26") then
                playerFrame.player1SplitHand2CardTotalText:SetText("26")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "27") then
                playerFrame.player1SplitHand2CardTotalText:SetText("27")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "28") then
                playerFrame.player1SplitHand2CardTotalText:SetText("28")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "29") then
                playerFrame.player1SplitHand2CardTotalText:SetText("29")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "30") then
                playerFrame.player1SplitHand2CardTotalText:SetText("30")
                playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 0, 0)
                turn = 23 -- Skip to Dealer 2nd Card
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.player1SplitHand2CardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.player1SplitHand2CardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.player1SplitHand2CardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.player1SplitHand2CardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.player1SplitHand2CardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.player1SplitHand2CardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.player1SplitHand2CardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.player1SplitHand2CardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.player1SplitHand2CardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.player1SplitHand2CardTotalText:SetText("13")
            elseif turn == 10 then
                if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                    if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                        turn = 23 -- Skip to Dealer 2nd Card
                    else
                        turn = 16 -- Skip to Player 1 3rd Card (Hand 2)
                    end
                end
            end
        end

    elseif turn == 2 then
        if string.find(message, "1 or 11") then
            PlaySoundFile(soundFilePaths[22])
            playerFrame.dealerCardTotalText:SetText("1 or 11")
        elseif string.find(message, "2") then
            PlaySoundFile(soundFilePaths[2])
            playerFrame.dealerCardTotalText:SetText("2")
        elseif string.find(message, "3") then
            PlaySoundFile(soundFilePaths[3])
            playerFrame.dealerCardTotalText:SetText("3")
        elseif string.find(message, "4") then
            PlaySoundFile(soundFilePaths[4])
            playerFrame.dealerCardTotalText:SetText("4")
        elseif string.find(message, "5") then
            PlaySoundFile(soundFilePaths[5])
            playerFrame.dealerCardTotalText:SetText("5")
        elseif string.find(message, "6") then
            PlaySoundFile(soundFilePaths[6])
            playerFrame.dealerCardTotalText:SetText("6")
        elseif string.find(message, "7") then
            PlaySoundFile(soundFilePaths[7])
            playerFrame.dealerCardTotalText:SetText("7")
        elseif string.find(message, "8") then
            PlaySoundFile(soundFilePaths[8])
            playerFrame.dealerCardTotalText:SetText("8")
        elseif string.find(message, "9") then
            PlaySoundFile(soundFilePaths[9])
            playerFrame.dealerCardTotalText:SetText("9")
        elseif string.find(message, "10") then
            PlaySoundFile(soundFilePaths[10])
            playerFrame.dealerCardTotalText:SetText("10")
        end

    elseif string.find(message, "Dealer") and string.find(message, "has") and not string.find(message, "turned") then
        if turn >= 24 then
            playerFrame.player1TurnArrow:Hide()
            playerFrame.player2TurnArrow:Hide()
            playerFrame.player3TurnArrow:Hide()
            playerFrame.player4TurnArrow:Hide()
            playerFrame.player5TurnArrow:Hide()
            if string.find(message, "2 or 12") then
                PlaySoundFile(soundFilePaths[23])
                playerFrame.dealerCardTotalText:SetText("2 or 12")
            elseif string.find(message, "3 or 13") then
                PlaySoundFile(soundFilePaths[24])
                playerFrame.dealerCardTotalText:SetText("3 or 13")
            elseif string.find(message, "4 or 14") then
                PlaySoundFile(soundFilePaths[25])
                playerFrame.dealerCardTotalText:SetText("4 or 14")
            elseif string.find(message, "5 or 15") then
                PlaySoundFile(soundFilePaths[26])
                playerFrame.dealerCardTotalText:SetText("5 or 15")
            elseif string.find(message, "6 or 16") then
                PlaySoundFile(soundFilePaths[27])
                playerFrame.dealerCardTotalText:SetText("6 or 16")
            elseif string.find(message, "14") then
                PlaySoundFile(soundFilePaths[14])
                playerFrame.dealerCardTotalText:SetText("14")
            elseif string.find(message, "15") then
                PlaySoundFile(soundFilePaths[15])
                playerFrame.dealerCardTotalText:SetText("15")
            elseif string.find(message, "16") then
                PlaySoundFile(soundFilePaths[16])
                playerFrame.dealerCardTotalText:SetText("16")
            elseif string.find(message, "17") then
                PlaySoundFile(soundFilePaths[17])
                playerFrame.dealerCardTotalText:SetText("17")
            elseif string.find(message, "18") then
                PlaySoundFile(soundFilePaths[18])
                playerFrame.dealerCardTotalText:SetText("18")
            elseif string.find(message, "19") then
                PlaySoundFile(soundFilePaths[19])
                playerFrame.dealerCardTotalText:SetText("19")
            elseif string.find(message, "20") then
                PlaySoundFile(soundFilePaths[20])
                playerFrame.dealerCardTotalText:SetText("20")
            elseif string.find(message, "21") then
                PlaySoundFile(soundFilePaths[21])
                playerFrame.dealerCardTotalText:SetText("21")
            elseif string.find(message, "22") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("22")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "23") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("23")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "24") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("24")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "25") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("25")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "26") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("26")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "27") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("27")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "28") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("28")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "29") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("29")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "30") then
                PlaySoundFile(soundFilePaths[112])
                playerFrame.dealerCardTotalText:SetText("30")
                playerFrame.dealerCardTotalText:SetTextColor(1, 0, 0)
            elseif string.find(message, "4") then
                PlaySoundFile(soundFilePaths[4])
                playerFrame.dealerCardTotalText:SetText("4")
            elseif string.find(message, "5") then
                PlaySoundFile(soundFilePaths[5])
                playerFrame.dealerCardTotalText:SetText("5")
            elseif string.find(message, "6") then
                PlaySoundFile(soundFilePaths[6])
                playerFrame.dealerCardTotalText:SetText("6")
            elseif string.find(message, "7") then
                PlaySoundFile(soundFilePaths[7])
                playerFrame.dealerCardTotalText:SetText("7")
            elseif string.find(message, "8") then
                PlaySoundFile(soundFilePaths[8])
                playerFrame.dealerCardTotalText:SetText("8")
            elseif string.find(message, "9") then
                PlaySoundFile(soundFilePaths[9])
                playerFrame.dealerCardTotalText:SetText("9")
            elseif string.find(message, "10") then
                PlaySoundFile(soundFilePaths[10])
                playerFrame.dealerCardTotalText:SetText("10")
            elseif string.find(message, "11") then
                PlaySoundFile(soundFilePaths[11])
                playerFrame.dealerCardTotalText:SetText("11")
            elseif string.find(message, "12") then
                PlaySoundFile(soundFilePaths[12])
                playerFrame.dealerCardTotalText:SetText("12")
            elseif string.find(message, "13") then
                PlaySoundFile(soundFilePaths[13])
                playerFrame.dealerCardTotalText:SetText("13")
            end
        end
    end
end








-- >> HANDLE MESSAGES <<
-- >> HANDLE MESSAGES <<
-- >> HANDLE MESSAGES <<

function HandleChatMessage(message)
    -- Players: 1
    if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
        HandleCardsP1(message)
    -- Players: 2
    elseif not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
        HandleCardsP2(message)
    -- Players: 3
    elseif not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
        HandleCardsP3(message)
    -- Players: 4
    elseif not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
        HandleCardsP4(message)
    -- Players: 5
    elseif not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
        HandleCardsP5(message)
    
    -- Players: 1, 2
    elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
        HandleCardsP12(message)
    -- Players: 1, 3
    elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
        HandleCardsP13(message)
    -- Players: 1, 4
    elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
        HandleCardsP14(message)
    -- Players: 1, 5
    elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
        HandleCardsP15(message)
    -- Players: 2, 3
    elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
        HandleCardsP23(message)
    -- Players: 2, 4
    elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
        HandleCardsP24(message)
    -- Players: 2, 5
    elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
        HandleCardsP25(message)
    -- Players: 3, 4
    elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
        HandleCardsP34(message)
    -- Players: 3, 5
    elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
        HandleCardsP35(message)
    -- Players: 4, 5
    elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
        HandleCardsP45(message)

    -- Players: 1, 2, 3
    elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then
        HandleCardsP123(message)
    -- Players: 1, 2, 4
    elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then
        HandleCardsP124(message)
    -- Players: 1, 2, 5
    elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then
        HandleCardsP125(message)
    -- Players: 1, 3, 4
    elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then
        HandleCardsP134(message)
    -- Players: 1, 3, 5
    elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then
        HandleCardsP135(message)
    -- Players: 1, 4, 5
    elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then
        HandleCardsP145(message)
    -- Players: 2, 3, 4
    elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then
        HandleCardsP234(message)
    -- Players: 2, 3, 5
    elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then
        HandleCardsP235(message)
    -- Players: 2, 4, 5
    elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then
        HandleCardsP245(message)
    -- Players: 3, 4, 5
    elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then
        HandleCardsP345(message)

    -- Players: 1, 2, 3, 4
    elseif player1Active and player2Active and player3Active and player4Active and not player5Active then
        HandleCardsP1234(message)
    -- Players: 1, 2, 3, 5
    elseif player1Active and player2Active and player3Active and not player4Active and player5Active then
        HandleCardsP1235(message)
    -- Players: 1, 2, 4, 5
    elseif player1Active and player2Active and not player3Active and player4Active and player5Active then
        HandleCardsP1245(message)
    -- Players: 1, 3, 4, 5
    elseif player1Active and not player2Active and player3Active and player4Active and player5Active then
        HandleCardsP1345(message)
    -- Players: 2, 3, 4, 5
    elseif not player1Active and player2Active and player3Active and player4Active and player5Active then
        HandleCardsP2345(message)

    -- Players: 1, 2, 3, 4, 5
    elseif player1Active and player2Active and player3Active and player4Active and player5Active then
        HandleCardsP12345(message)
    end
end








-- >> EXTRA FUNCTIONS <<
-- >> EXTRA FUNCTIONS <<
-- >> EXTRA FUNCTIONS <<

function timerReset()
    timerFrame:Hide()
    timerBetsFrame:Hide()

    -- >> PLAYER 1 <<
    if player1CountdownTimer then
        player1CountdownTimer:Cancel()
    end
    if player1SplitH1CountdownTimer then
        player1SplitH1CountdownTimer:Cancel()
    end
    if player1SplitH2CountdownTimer then
        player1SplitH2CountdownTimer:Cancel()
    end
    timerFrame.player1TimerText:SetText("")
    timerFrame.player1TimerText:Hide()

    -- >> PLAYER 2 <<
    if player2CountdownTimer then
        player2CountdownTimer:Cancel()
    end
    if player2SplitH1CountdownTimer then
        player2SplitH1CountdownTimer:Cancel()
    end
    if player2SplitH2CountdownTimer then
        player2SplitH2CountdownTimer:Cancel()
    end
    timerFrame.player2TimerText:SetText("")
    timerFrame.player2TimerText:Hide()

    -- >> PLAYER 3 <<
    if player3CountdownTimer then
        player3CountdownTimer:Cancel()
    end
    if player3SplitH1CountdownTimer then
        player3SplitH1CountdownTimer:Cancel()
    end
    if player3SplitH2CountdownTimer then
        player3SplitH2CountdownTimer:Cancel()
    end
    timerFrame.player3TimerText:SetText("")
    timerFrame.player3TimerText:Hide()

    -- >> PLAYER 4 <<
    if player4CountdownTimer then
        player4CountdownTimer:Cancel()
    end
    if player4SplitH1CountdownTimer then
        player4SplitH1CountdownTimer:Cancel()
    end
    if player4SplitH2CountdownTimer then
        player4SplitH2CountdownTimer:Cancel()
    end
    timerFrame.player4TimerText:SetText("")
    timerFrame.player4TimerText:Hide()

    -- >> PLAYER 5 <<
    if player5CountdownTimer then
        player5CountdownTimer:Cancel()
    end
    if player5SplitH1CountdownTimer then
        player5SplitH1CountdownTimer:Cancel()
    end
    if player5SplitH2CountdownTimer then
        player5SplitH2CountdownTimer:Cancel()
    end
    timerFrame.player5TimerText:SetText("")
    timerFrame.player5TimerText:Hide()

    timerBetsFrame.timerTextBets:SetText("")
    timerBetsFrame.timerTextBets:Hide()
    countdownDuration = 30

end
function roundStarted()

    -- "Place your bets" message
    timerBetsFrame.timerTextBets:Hide()
    timerBetsFrame:Hide()
    countdownDuration = 30

    -- Player 1 bet buttons disabled
    player1ConfirmMainBetButton:Disable()
    player1ConfirmPPBetButton:Disable()
    player1Confirm213BetButton:Disable()
    player1PreloadBetButton:Disable()
    playerFrame.player1DealNowButton:Hide()
    playerFrame.player1DealNowButton:Disable()
    playerFrame.takeSeat1Button:Disable()
    playerFrame.leaveSeat1Button:Disable()

    -- Player 2 bet buttons disabled
    player2ConfirmMainBetButton:Disable()
    player2ConfirmPPBetButton:Disable()
    player2Confirm213BetButton:Disable()
    player2PreloadBetButton:Disable()
    playerFrame.player2DealNowButton:Hide()
    playerFrame.player2DealNowButton:Disable()
    playerFrame.takeSeat2Button:Disable()
    playerFrame.leaveSeat2Button:Disable()

    -- Player 3 bet buttons disabled
    player3ConfirmMainBetButton:Disable()
    player3ConfirmPPBetButton:Disable()
    player3Confirm213BetButton:Disable()
    player3PreloadBetButton:Disable()
    playerFrame.player3DealNowButton:Hide()
    playerFrame.player3DealNowButton:Disable()
    playerFrame.takeSeat3Button:Disable()
    playerFrame.leaveSeat3Button:Disable()

    -- Player 4 bet buttons disabled
    player4ConfirmMainBetButton:Disable()
    player4ConfirmPPBetButton:Disable()
    player4Confirm213BetButton:Disable()
    player4PreloadBetButton:Disable()
    playerFrame.player4DealNowButton:Hide()
    playerFrame.player4DealNowButton:Disable()
    playerFrame.takeSeat4Button:Disable()
    playerFrame.leaveSeat4Button:Disable()

    -- Player 5 bet buttons disabled
    player5ConfirmMainBetButton:Disable()
    player5ConfirmPPBetButton:Disable()
    player5Confirm213BetButton:Disable()
    player5PreloadBetButton:Disable()
    playerFrame.player5DealNowButton:Hide()
    playerFrame.player5DealNowButton:Disable()
    playerFrame.takeSeat5Button:Disable()
    playerFrame.leaveSeat5Button:Disable()

end
function insuranceAvailable()

    if playerName == unitName1 then
        -- Player 1
        if player1Active and playerFrame.player1CardTotalText:GetText() == "Blackjack" then
            playerFrame.player1InsuranceYesButton:Show()
            playerFrame.player1InsuranceNoButton:Show()
            playerFrame.player1InsuranceYesButton:Disable()
            playerFrame.player1InsuranceNoButton:Disable()
            playerFrame.player1InsuranceTitle:Show()
            playerFrame.player1InsuranceSubtitle:Show()
        else
            playerFrame.player1InsuranceYesButton:Show()
            playerFrame.player1InsuranceNoButton:Show()
            playerFrame.player1InsuranceYesButton:Enable()
            playerFrame.player1InsuranceNoButton:Enable()
            playerFrame.player1InsuranceTitle:Show()
            playerFrame.player1InsuranceSubtitle:Show()
        end
    elseif playerName == unitName2 then
        -- Player 2
        if player2Active and playerFrame.player2CardTotalText:GetText() == "Blackjack" then
            playerFrame.player2InsuranceYesButton:Show()
            playerFrame.player2InsuranceNoButton:Show()
            playerFrame.player2InsuranceYesButton:Disable()
            playerFrame.player2InsuranceNoButton:Disable()
            playerFrame.player2InsuranceTitle:Show()
            playerFrame.player2InsuranceSubtitle:Show()
        else
            playerFrame.player2InsuranceYesButton:Show()
            playerFrame.player2InsuranceNoButton:Show()
            playerFrame.player2InsuranceYesButton:Enable()
            playerFrame.player2InsuranceNoButton:Enable()
            playerFrame.player2InsuranceTitle:Show()
            playerFrame.player2InsuranceSubtitle:Show()
        end
    elseif playerName == unitName3 then
        -- Player 3
        if player3Active and playerFrame.player3CardTotalText:GetText() == "Blackjack" then
            playerFrame.player3InsuranceYesButton:Show()
            playerFrame.player3InsuranceNoButton:Show()
            playerFrame.player3InsuranceYesButton:Disable()
            playerFrame.player3InsuranceNoButton:Disable()
            playerFrame.player3InsuranceTitle:Show()
            playerFrame.player3InsuranceSubtitle:Show()
        else
            playerFrame.player3InsuranceYesButton:Show()
            playerFrame.player3InsuranceNoButton:Show()
            playerFrame.player3InsuranceYesButton:Enable()
            playerFrame.player3InsuranceNoButton:Enable()
            playerFrame.player3InsuranceTitle:Show()
            playerFrame.player3InsuranceSubtitle:Show()
        end
    elseif playerName == unitName4 then
        -- Player 4
        if player4Active and playerFrame.player4CardTotalText:GetText() == "Blackjack" then
            playerFrame.player4InsuranceYesButton:Show()
            playerFrame.player4InsuranceNoButton:Show()
            playerFrame.player4InsuranceYesButton:Disable()
            playerFrame.player4InsuranceNoButton:Disable()
            playerFrame.player4InsuranceTitle:Show()
            playerFrame.player4InsuranceSubtitle:Show()
        else
            playerFrame.player4InsuranceYesButton:Show()
            playerFrame.player4InsuranceNoButton:Show()
            playerFrame.player4InsuranceYesButton:Enable()
            playerFrame.player4InsuranceNoButton:Enable()
            playerFrame.player4InsuranceTitle:Show()
            playerFrame.player4InsuranceSubtitle:Show()
        end
    elseif playerName == unitName5 then
        -- Player 5
        if player5Active and playerFrame.player5CardTotalText:GetText() == "Blackjack" then
            playerFrame.player5InsuranceYesButton:Show()
            playerFrame.player5InsuranceNoButton:Show()
            playerFrame.player5InsuranceYesButton:Disable()
            playerFrame.player5InsuranceNoButton:Disable()
            playerFrame.player5InsuranceTitle:Show()
            playerFrame.player5InsuranceSubtitle:Show()
        else
            playerFrame.player5InsuranceYesButton:Show()
            playerFrame.player5InsuranceNoButton:Show()
            playerFrame.player5InsuranceYesButton:Enable()
            playerFrame.player5InsuranceNoButton:Enable()
            playerFrame.player5InsuranceTitle:Show()
            playerFrame.player5InsuranceSubtitle:Show()
        end
    end
end
function betReset()

    playerFrame.leaveSeat1Button:Enable()
    playerFrame.leaveSeat2Button:Enable()
    playerFrame.leaveSeat3Button:Enable()
    playerFrame.leaveSeat4Button:Enable()
    playerFrame.leaveSeat5Button:Enable()

    if tableSpectator == true then
        if playerFrame.player1Name:GetText() == "Seat Empty" then
            playerFrame.takeSeat1Button:Enable()
        elseif playerFrame.player2Name:GetText() == "Seat Empty" then
            playerFrame.takeSeat2Button:Enable()
        elseif playerFrame.player3Name:GetText() == "Seat Empty" then
            playerFrame.takeSeat3Button:Enable()
        elseif playerFrame.player4Name:GetText() == "Seat Empty" then
            playerFrame.takeSeat4Button:Enable()
        elseif playerFrame.player5Name:GetText() == "Seat Empty" then
            playerFrame.takeSeat5Button:Enable()
        end
    end

    -- >>> PLAYER 1 <<<
    -- >>> PLAYER 1 <<<
    -- >>> PLAYER 1 <<<

    -- Editboxes / Bets
    if tableLocked == true then
        player1MainBetEditBox:SetText("")
        player1MainBetEditBox:Enable()
        player1PPBetEditBox:SetText("")
        player1PPBetEditBox:Enable()
        player1213BetEditBox:SetText("")
        player1213BetEditBox:Enable()
    else
        player1MainBetEditBox:SetText("")
        player1MainBetEditBox:Enable()
        player1PPBetEditBox:SetText("")
        player1PPBetEditBox:Enable()
        player1213BetEditBox:SetText("")
        player1213BetEditBox:Enable()
        player1ConfirmMainBetButton:Enable()
        player1ConfirmPPBetButton:Enable()
        player1Confirm213BetButton:Enable()
        player1PreloadBetButton:Enable()
    end
    -- Standard Buttons
    if playerName == unitName1 then
        player1MainBetEditBox:Show()
        player1ConfirmMainBetButton:Show()
        playerFrame.player1HitButton:Show()
        playerFrame.player1StandButton:Show()
        playerFrame.player1DoubleButton:Show()
        playerFrame.player1SplitButton:Show()
        playerFrame.player1InsuranceYesButton:Hide()
        playerFrame.player1InsuranceNoButton:Hide()
        playerFrame.player1InsuranceTitle:Hide()
        playerFrame.player1InsuranceSubtitle:Hide()
        playerFrame.player1DealNowButton:Show()
        playerFrame.player1DealNowButton:Disable()
    end
    playerFrame.player1HitButton:Disable()
    playerFrame.player1StandButton:Disable()
    playerFrame.player1DoubleButton:Disable()
    playerFrame.player1SplitButton:Disable()
    playerFrame.player1InsuranceYesButton:Disable()
    playerFrame.player1InsuranceNoButton:Disable()
    -- Bet Amount Labels
    player1MainBetAmount:Hide()
    player1MainBetAmount:SetTextColor(1, 1, 1)
    player1SplitH1BetAmount:Hide()
    player1SplitH1BetAmount:SetTextColor(1, 1, 1)
    player1SplitH2BetAmount:Hide()
    player1SplitH2BetAmount:SetTextColor(1, 1, 1)
    player1PPBetAmount:Hide()
    player1PPBetAmount:SetTextColor(1, 1, 1)
    player1PPBetAmount:SetPoint("CENTER", playerFrame, 275, 60)
    player1213BetAmount:Hide()
    player1213BetAmount:SetTextColor(1, 1, 1)
    player1213BetAmount:SetPoint("CENTER", playerFrame, 345, 156)
    playerFrame.player1InsuranceBetAmount:SetText("")
    playerFrame.player1InsuranceBetAmount:Hide()
    -- Coins Images
    playerFrame.player1MainBetCoins:Hide()
    playerFrame.player1NormalWinCoins:Hide()
    playerFrame.player1SplitHand2Coins:Hide()
    playerFrame.player1SplitHand2DoubleCoins:Hide()
    playerFrame.player1SplitHand2NormalWinCoins:Hide()
    playerFrame.player1SplitHand1Coins:Hide()
    playerFrame.player1SplitHand1DoubleCoins:Hide()
    playerFrame.player1SplitHand1NormalWinCoins:Hide()
    playerFrame.player1BJWinCoins:Hide()
    playerFrame.player1SplitHand2BJWinCoins:Hide()
    playerFrame.player1SplitHand1BJWinCoins:Hide()
    playerFrame.player1DoubleBetCoins:Hide()
    playerFrame.player1PPBetCoins:Hide()
    playerFrame.player1213BetCoins:Hide()
    playerFrame.player1PPWinCoins:Hide()
    playerFrame.player1213WinCoins:Hide()
    -- Insurance Icons
    player1InsuranceYesIcon:Hide()
    player1InsuranceNoIcon:Hide()
    -- Split Buttons & Editboxes
    playerFrame.player1SplitH1Title:Hide()
    playerFrame.player1SplitH2Title:Hide()
    player1SplitH1EditBox:Hide()
    player1SplitH2EditBox:Hide()
    playerFrame.player1HitButtonSplitH1:Hide()
    playerFrame.player1StandButtonSplitH1:Hide()
    playerFrame.player1DoubleButtonSplitH1:Hide()
    playerFrame.player1HitButtonSplitH2:Hide()
    playerFrame.player1StandButtonSplitH2:Hide()
    playerFrame.player1DoubleButtonSplitH2:Hide()
    -- Card Total Text
    playerFrame.player1CardTotalText:SetTextColor(1, 1, 1)
    playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 1, 1)
    playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 1, 1)
    -- Card Images / Filenames
    player1MainCardName1 = nil
    player1MainCardName2 = nil
    player1MainCardName3 = nil
    player1MainCardName4 = nil
    player1MainCardName5 = nil
    player1MainCardName6 = nil
    player1MainCardName7 = nil
    player1MainCardFileName1 = nil
    player1MainCardFileName2 = nil
    player1MainCardFileName3 = nil
    player1MainCardFileName4 = nil
    player1MainCardFileName5 = nil
    player1MainCardFileName6 = nil
    player1MainCardFileName7 = nil
    player1H1CardName1 = nil
    player1H1CardName2 = nil
    player1H1CardName3 = nil
    player1H1CardName4 = nil
    player1H1CardName5 = nil
    player1H1CardName6 = nil
    player1H1CardName7 = nil
    player1H1CardFileName1 = nil
    player1H1CardFileName2 = nil
    player1H1CardFileName3 = nil
    player1H1CardFileName4 = nil
    player1H1CardFileName5 = nil
    player1H1CardFileName6 = nil
    player1H1CardFileName7 = nil
    player1H2CardName1 = nil
    player1H2CardName2 = nil
    player1H2CardName3 = nil
    player1H2CardName4 = nil
    player1H2CardName5 = nil
    player1H2CardName6 = nil
    player1H2CardName7 = nil
    player1H2CardFileName1 = nil
    player1H2CardFileName2 = nil
    player1H2CardFileName3 = nil
    player1H2CardFileName4 = nil
    player1H2CardFileName5 = nil
    player1H2CardFileName6 = nil
    player1H2CardFileName7 = nil
    -- Timers
    timerFrame.player1TimerText:SetText("")
    timerFrame.player1TimerText:Hide()
    -- Variables
    player1NumberOfCards = 0
    player1NumberOfCardsH1 = 0
    player1NumberOfCardsH2 = 0
    player1SessionWin = 0
    player1DoubleToggle = false
    player1DoubleHand1Toggle = false
    player1DoubleHand2Toggle = false
    player1SplitToggle = false
    player1PPSideBetWin = false
    player1213SideBetWin = false
    player1Active = false
    player1SessionWinCalled = false

    if player1dealtCardsFrame:IsShown() then
        player1dealtCardsFrame.notStartedYetText:Show()
    end




    -- >>> PLAYER 2 <<<
    -- >>> PLAYER 2 <<<
    -- >>> PLAYER 2 <<<
    
    -- Editboxes / Bets
    if tableLocked == true then
        player2MainBetEditBox:SetText("")
        player2MainBetEditBox:Enable()
        player2PPBetEditBox:SetText("")
        player2PPBetEditBox:Enable()
        player2213BetEditBox:SetText("")
        player2213BetEditBox:Enable()
    else
        player2MainBetEditBox:SetText("")
        player2MainBetEditBox:Enable()
        player2PPBetEditBox:SetText("")
        player2PPBetEditBox:Enable()
        player2213BetEditBox:SetText("")
        player2213BetEditBox:Enable()
        player2ConfirmMainBetButton:Enable()
        player2ConfirmPPBetButton:Enable()
        player2Confirm213BetButton:Enable()
        player2PreloadBetButton:Enable()
    end
    -- Standard Buttons
    if playerName == unitName2 then
        player2MainBetEditBox:Show()
        player2ConfirmMainBetButton:Show()
        playerFrame.player2HitButton:Show()
        playerFrame.player2StandButton:Show()
        playerFrame.player2DoubleButton:Show()
        playerFrame.player2SplitButton:Show()
        playerFrame.player2InsuranceYesButton:Hide()
        playerFrame.player2InsuranceNoButton:Hide()
        playerFrame.player2InsuranceTitle:Hide()
        playerFrame.player2InsuranceSubtitle:Hide()
        playerFrame.player2DealNowButton:Show()
        playerFrame.player2DealNowButton:Disable()
    end
    playerFrame.player2HitButton:Disable()
    playerFrame.player2StandButton:Disable()
    playerFrame.player2DoubleButton:Disable()
    playerFrame.player2SplitButton:Disable()
    playerFrame.player2InsuranceYesButton:Disable()
    playerFrame.player2InsuranceNoButton:Disable()
    -- Bet Amount Labels
    player2MainBetAmount:Hide()
    player2MainBetAmount:SetTextColor(1, 1, 1)
    player2SplitH1BetAmount:Hide()
    player2SplitH1BetAmount:SetTextColor(1, 1, 1)
    player2SplitH2BetAmount:Hide()
    player2SplitH2BetAmount:SetTextColor(1, 1, 1)
    player2PPBetAmount:Hide()
    player2PPBetAmount:SetTextColor(1, 1, 1)
    player2PPBetAmount:SetPoint("CENTER", playerFrame, 123, -23)
    player2213BetAmount:Hide()
    player2213BetAmount:SetTextColor(1, 1, 1)
    player2213BetAmount:SetPoint("CENTER", playerFrame, 231, 29)
    playerFrame.player2InsuranceBetAmount:SetText("")
    playerFrame.player2InsuranceBetAmount:Hide()
    -- Coins Images
    playerFrame.player2MainBetCoins:Hide()
    playerFrame.player2NormalWinCoins:Hide()
    playerFrame.player2SplitHand2Coins:Hide()
    playerFrame.player2SplitHand2DoubleCoins:Hide()
    playerFrame.player2SplitHand2NormalWinCoins:Hide()
    playerFrame.player2SplitHand1Coins:Hide()
    playerFrame.player2SplitHand1DoubleCoins:Hide()
    playerFrame.player2SplitHand1NormalWinCoins:Hide()
    playerFrame.player2BJWinCoins:Hide()
    playerFrame.player2SplitHand2BJWinCoins:Hide()
    playerFrame.player2SplitHand1BJWinCoins:Hide()
    playerFrame.player2DoubleBetCoins:Hide()
    playerFrame.player2PPBetCoins:Hide()
    playerFrame.player2213BetCoins:Hide()
    playerFrame.player2PPWinCoins:Hide()
    playerFrame.player2213WinCoins:Hide()
    -- Insurance Icons
    player2InsuranceYesIcon:Hide()
    player2InsuranceNoIcon:Hide()
    -- Split Buttons & Editboxes
    playerFrame.player2SplitH1Title:Hide()
    playerFrame.player2SplitH2Title:Hide()
    player2SplitH1EditBox:Hide()
    player2SplitH2EditBox:Hide()
    playerFrame.player2HitButtonSplitH1:Hide()
    playerFrame.player2StandButtonSplitH1:Hide()
    playerFrame.player2DoubleButtonSplitH1:Hide()
    playerFrame.player2HitButtonSplitH2:Hide()
    playerFrame.player2StandButtonSplitH2:Hide()
    playerFrame.player2DoubleButtonSplitH2:Hide()
    -- Card Total Text
    playerFrame.player2CardTotalText:SetTextColor(1, 1, 1)
    playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 1, 1)
    playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 1, 1)
    -- Card Images / Filenames
    player2MainCardName1 = nil
    player2MainCardName2 = nil
    player2MainCardName3 = nil
    player2MainCardName4 = nil
    player2MainCardName5 = nil
    player2MainCardName6 = nil
    player2MainCardName7 = nil
    player2MainCardFileName1 = nil
    player2MainCardFileName2 = nil
    player2MainCardFileName3 = nil
    player2MainCardFileName4 = nil
    player2MainCardFileName5 = nil
    player2MainCardFileName6 = nil
    player2MainCardFileName7 = nil
    player2H1CardName1 = nil
    player2H1CardName2 = nil
    player2H1CardName3 = nil
    player2H1CardName4 = nil
    player2H1CardName5 = nil
    player2H1CardName6 = nil
    player2H1CardName7 = nil
    player2H1CardFileName1 = nil
    player2H1CardFileName2 = nil
    player2H1CardFileName3 = nil
    player2H1CardFileName4 = nil
    player2H1CardFileName5 = nil
    player2H1CardFileName6 = nil
    player2H1CardFileName7 = nil
    player2H2CardName1 = nil
    player2H2CardName2 = nil
    player2H2CardName3 = nil
    player2H2CardName4 = nil
    player2H2CardName5 = nil
    player2H2CardName6 = nil
    player2H2CardName7 = nil
    player2H2CardFileName1 = nil
    player2H2CardFileName2 = nil
    player2H2CardFileName3 = nil
    player2H2CardFileName4 = nil
    player2H2CardFileName5 = nil
    player2H2CardFileName6 = nil
    player2H2CardFileName7 = nil
    -- Timers
    timerFrame.player2TimerText:SetText("")
    timerFrame.player2TimerText:Hide()
    -- Variables
    player2NumberOfCards = 0
    player2NumberOfCardsH1 = 0
    player2NumberOfCardsH2 = 0
    player2SessionWin = 0
    player2DoubleToggle = false
    player2DoubleHand1Toggle = false
    player2DoubleHand2Toggle = false
    player2SplitToggle = false
    player2PPSideBetWin = false
    player2213SideBetWin = false
    player2Active = false
    player2SessionWinCalled = false

    if player2dealtCardsFrame:IsShown() then
        player2dealtCardsFrame.notStartedYetText:Show()
    end




    -- >>> PLAYER 3 <<<
    -- >>> PLAYER 3 <<<
    -- >>> PLAYER 3 <<<
    
    -- Editboxes / Bets
    if tableLocked == true then
        player3MainBetEditBox:SetText("")
        player3MainBetEditBox:Enable()
        player3PPBetEditBox:SetText("")
        player3PPBetEditBox:Enable()
        player3213BetEditBox:SetText("")
        player3213BetEditBox:Enable()
    else
        player3MainBetEditBox:SetText("")
        player3MainBetEditBox:Enable()
        player3PPBetEditBox:SetText("")
        player3PPBetEditBox:Enable()
        player3213BetEditBox:SetText("")
        player3213BetEditBox:Enable()
        player3ConfirmMainBetButton:Enable()
        player3ConfirmPPBetButton:Enable()
        player3Confirm213BetButton:Enable()
        player3PreloadBetButton:Enable()
    end
    -- Standard Buttons
    if playerName == unitName3 then
        player3MainBetEditBox:Show()
        player3ConfirmMainBetButton:Show()
        playerFrame.player3HitButton:Show()
        playerFrame.player3StandButton:Show()
        playerFrame.player3DoubleButton:Show()
        playerFrame.player3SplitButton:Show()
        playerFrame.player3InsuranceYesButton:Hide()
        playerFrame.player3InsuranceNoButton:Hide()
        playerFrame.player3InsuranceTitle:Hide()
        playerFrame.player3InsuranceSubtitle:Hide()
        playerFrame.player3DealNowButton:Show()
        playerFrame.player3DealNowButton:Disable()
    end
    playerFrame.player3HitButton:Disable()
    playerFrame.player3StandButton:Disable()
    playerFrame.player3DoubleButton:Disable()
    playerFrame.player3SplitButton:Disable()
    playerFrame.player3InsuranceYesButton:Disable()
    playerFrame.player3InsuranceNoButton:Disable()
    -- Bet Amount Labels
    player3MainBetAmount:Hide()
    player3MainBetAmount:SetTextColor(1, 1, 1)
    player3SplitH1BetAmount:Hide()
    player3SplitH1BetAmount:SetTextColor(1, 1, 1)
    player3SplitH2BetAmount:Hide()
    player3SplitH2BetAmount:SetTextColor(1, 1, 1)
    player3PPBetAmount:Hide()
    player3PPBetAmount:SetTextColor(1, 1, 1)
    player3PPBetAmount:SetPoint("CENTER", playerFrame, -51, -35)
    player3213BetAmount:Hide()
    player3213BetAmount:SetTextColor(1, 1, 1)
    player3213BetAmount:SetPoint("CENTER", playerFrame, 67, -36)
    playerFrame.player3InsuranceBetAmount:SetText("")
    playerFrame.player3InsuranceBetAmount:Hide()
    -- Coins Images
    playerFrame.player3MainBetCoins:Hide()
    playerFrame.player3NormalWinCoins:Hide()
    playerFrame.player3SplitHand2Coins:Hide()
    playerFrame.player3SplitHand2DoubleCoins:Hide()
    playerFrame.player3SplitHand2NormalWinCoins:Hide()
    playerFrame.player3SplitHand1Coins:Hide()
    playerFrame.player3SplitHand1DoubleCoins:Hide()
    playerFrame.player3SplitHand1NormalWinCoins:Hide()
    playerFrame.player3BJWinCoins:Hide()
    playerFrame.player3SplitHand2BJWinCoins:Hide()
    playerFrame.player3SplitHand1BJWinCoins:Hide()
    playerFrame.player3DoubleBetCoins:Hide()
    playerFrame.player3PPBetCoins:Hide()
    playerFrame.player3213BetCoins:Hide()
    playerFrame.player3PPWinCoins:Hide()
    playerFrame.player3213WinCoins:Hide()
    -- Insurance Icons
    player3InsuranceYesIcon:Hide()
    player3InsuranceNoIcon:Hide()
    -- Split Buttons & Editboxes
    playerFrame.player3SplitH1Title:Hide()
    playerFrame.player3SplitH2Title:Hide()
    player3SplitH1EditBox:Hide()
    player3SplitH2EditBox:Hide()
    playerFrame.player3HitButtonSplitH1:Hide()
    playerFrame.player3StandButtonSplitH1:Hide()
    playerFrame.player3DoubleButtonSplitH1:Hide()
    playerFrame.player3HitButtonSplitH2:Hide()
    playerFrame.player3StandButtonSplitH2:Hide()
    playerFrame.player3DoubleButtonSplitH2:Hide()
    -- Card Total Text
    playerFrame.player3CardTotalText:SetTextColor(1, 1, 1)
    playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 1, 1)
    playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 1, 1)
    -- Card Images / Filenames
    player3MainCardName1 = nil
    player3MainCardName2 = nil
    player3MainCardName3 = nil
    player3MainCardName4 = nil
    player3MainCardName5 = nil
    player3MainCardName6 = nil
    player3MainCardName7 = nil
    player3MainCardFileName1 = nil
    player3MainCardFileName2 = nil
    player3MainCardFileName3 = nil
    player3MainCardFileName4 = nil
    player3MainCardFileName5 = nil
    player3MainCardFileName6 = nil
    player3MainCardFileName7 = nil
    player3H1CardName1 = nil
    player3H1CardName2 = nil
    player3H1CardName3 = nil
    player3H1CardName4 = nil
    player3H1CardName5 = nil
    player3H1CardName6 = nil
    player3H1CardName7 = nil
    player3H1CardFileName1 = nil
    player3H1CardFileName2 = nil
    player3H1CardFileName3 = nil
    player3H1CardFileName4 = nil
    player3H1CardFileName5 = nil
    player3H1CardFileName6 = nil
    player3H1CardFileName7 = nil
    player3H2CardName1 = nil
    player3H2CardName2 = nil
    player3H2CardName3 = nil
    player3H2CardName4 = nil
    player3H2CardName5 = nil
    player3H2CardName6 = nil
    player3H2CardName7 = nil
    player3H2CardFileName1 = nil
    player3H2CardFileName2 = nil
    player3H2CardFileName3 = nil
    player3H2CardFileName4 = nil
    player3H2CardFileName5 = nil
    player3H2CardFileName6 = nil
    player3H2CardFileName7 = nil
    -- Timers
    timerFrame.player3TimerText:SetText("")
    timerFrame.player3TimerText:Hide()
    -- Variables
    player3NumberOfCards = 0
    player3NumberOfCardsH1 = 0
    player3NumberOfCardsH2 = 0
    player3SessionWin = 0
    player3DoubleToggle = false
    player3DoubleHand1Toggle = false
    player3DoubleHand2Toggle = false
    player3SplitToggle = false
    player3PPSideBetWin = false
    player3213SideBetWin = false
    player3Active = false
    player3SessionWinCalled = false

    if player3dealtCardsFrame:IsShown() then
        player3dealtCardsFrame.notStartedYetText:Show()
    end



    -- >>> PLAYER 4 <<<
    -- >>> PLAYER 4 <<<
    -- >>> PLAYER 4 <<<
    
    -- Editboxes / Bets
    if tableLocked == true then
        player4MainBetEditBox:SetText("")
        player4MainBetEditBox:Enable()
        player4PPBetEditBox:SetText("")
        player4PPBetEditBox:Enable()
        player4213BetEditBox:SetText("")
        player4213BetEditBox:Enable()
    else
        player4MainBetEditBox:SetText("")
        player4MainBetEditBox:Enable()
        player4PPBetEditBox:SetText("")
        player4PPBetEditBox:Enable()
        player4213BetEditBox:SetText("")
        player4213BetEditBox:Enable()
        player4ConfirmMainBetButton:Enable()
        player4ConfirmPPBetButton:Enable()
        player4Confirm213BetButton:Enable()
        player4PreloadBetButton:Enable()
    end
    -- Standard Buttons
    if playerName == unitName4 then
        player4MainBetEditBox:Show()
        player4ConfirmMainBetButton:Show()
        playerFrame.player4HitButton:Show()
        playerFrame.player4StandButton:Show()
        playerFrame.player4DoubleButton:Show()
        playerFrame.player4SplitButton:Show()
        playerFrame.player4InsuranceYesButton:Hide()
        playerFrame.player4InsuranceNoButton:Hide()
        playerFrame.player4InsuranceTitle:Hide()
        playerFrame.player4InsuranceSubtitle:Hide()
        playerFrame.player4DealNowButton:Show()
        playerFrame.player4DealNowButton:Disable()
    end
    playerFrame.player4HitButton:Disable()
    playerFrame.player4StandButton:Disable()
    playerFrame.player4DoubleButton:Disable()
    playerFrame.player4SplitButton:Disable()
    playerFrame.player4InsuranceYesButton:Disable()
    playerFrame.player4InsuranceNoButton:Disable()
    -- Bet Amount Labels
    player4MainBetAmount:Hide()
    player4MainBetAmount:SetTextColor(1, 1, 1)
    player4SplitH1BetAmount:Hide()
    player4SplitH1BetAmount:SetTextColor(1, 1, 1)
    player4SplitH2BetAmount:Hide()
    player4SplitH2BetAmount:SetTextColor(1, 1, 1)
    player4PPBetAmount:Hide()
    player4PPBetAmount:SetTextColor(1, 1, 1)
    player4PPBetAmount:SetPoint("CENTER", playerFrame, -219, 26)
    player4213BetAmount:Hide()
    player4213BetAmount:SetTextColor(1, 1, 1)
    player4213BetAmount:SetPoint("CENTER", playerFrame, -107, -25)
    playerFrame.player4InsuranceBetAmount:SetText("")
    playerFrame.player4InsuranceBetAmount:Hide()
    -- Coins Images
    playerFrame.player4MainBetCoins:Hide()
    playerFrame.player4NormalWinCoins:Hide()
    playerFrame.player4SplitHand2Coins:Hide()
    playerFrame.player4SplitHand2DoubleCoins:Hide()
    playerFrame.player4SplitHand2NormalWinCoins:Hide()
    playerFrame.player4SplitHand1Coins:Hide()
    playerFrame.player4SplitHand1DoubleCoins:Hide()
    playerFrame.player4SplitHand1NormalWinCoins:Hide()
    playerFrame.player4BJWinCoins:Hide()
    playerFrame.player4SplitHand2BJWinCoins:Hide()
    playerFrame.player4SplitHand1BJWinCoins:Hide()
    playerFrame.player4DoubleBetCoins:Hide()
    playerFrame.player4PPBetCoins:Hide()
    playerFrame.player4213BetCoins:Hide()
    playerFrame.player4PPWinCoins:Hide()
    playerFrame.player4213WinCoins:Hide()
    -- Insurance Icons
    player4InsuranceYesIcon:Hide()
    player4InsuranceNoIcon:Hide()
    -- Split Buttons & Editboxes
    playerFrame.player4SplitH1Title:Hide()
    playerFrame.player4SplitH2Title:Hide()
    player4SplitH1EditBox:Hide()
    player4SplitH2EditBox:Hide()
    playerFrame.player4HitButtonSplitH1:Hide()
    playerFrame.player4StandButtonSplitH1:Hide()
    playerFrame.player4DoubleButtonSplitH1:Hide()
    playerFrame.player4HitButtonSplitH2:Hide()
    playerFrame.player4StandButtonSplitH2:Hide()
    playerFrame.player4DoubleButtonSplitH2:Hide()
    -- Card Total Text
    playerFrame.player4CardTotalText:SetTextColor(1, 1, 1)
    playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 1, 1)
    playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 1, 1)
    -- Card Images / Filenames
    player4MainCardName1 = nil
    player4MainCardName2 = nil
    player4MainCardName3 = nil
    player4MainCardName4 = nil
    player4MainCardName5 = nil
    player4MainCardName6 = nil
    player4MainCardName7 = nil
    player4MainCardFileName1 = nil
    player4MainCardFileName2 = nil
    player4MainCardFileName3 = nil
    player4MainCardFileName4 = nil
    player4MainCardFileName5 = nil
    player4MainCardFileName6 = nil
    player4MainCardFileName7 = nil
    player4H1CardName1 = nil
    player4H1CardName2 = nil
    player4H1CardName3 = nil
    player4H1CardName4 = nil
    player4H1CardName5 = nil
    player4H1CardName6 = nil
    player4H1CardName7 = nil
    player4H1CardFileName1 = nil
    player4H1CardFileName2 = nil
    player4H1CardFileName3 = nil
    player4H1CardFileName4 = nil
    player4H1CardFileName5 = nil
    player4H1CardFileName6 = nil
    player4H1CardFileName7 = nil
    player4H2CardName1 = nil
    player4H2CardName2 = nil
    player4H2CardName3 = nil
    player4H2CardName4 = nil
    player4H2CardName5 = nil
    player4H2CardName6 = nil
    player4H2CardName7 = nil
    player4H2CardFileName1 = nil
    player4H2CardFileName2 = nil
    player4H2CardFileName3 = nil
    player4H2CardFileName4 = nil
    player4H2CardFileName5 = nil
    player4H2CardFileName6 = nil
    player4H2CardFileName7 = nil
    -- Timers
    timerFrame.player4TimerText:SetText("")
    timerFrame.player4TimerText:Hide()
    -- Variables
    player4NumberOfCards = 0
    player4NumberOfCardsH1 = 0
    player4NumberOfCardsH2 = 0
    player4SessionWin = 0
    player4DoubleToggle = false
    player4DoubleHand1Toggle = false
    player4DoubleHand2Toggle = false
    player4SplitToggle = false
    player4PPSideBetWin = false
    player4213SideBetWin = false
    player4Active = false
    player4SessionWinCalled = false

    if player4dealtCardsFrame:IsShown() then
        player4dealtCardsFrame.notStartedYetText:Show()
    end



    -- >>> PLAYER 5 <<<
    -- >>> PLAYER 5 <<<
    -- >>> PLAYER 5 <<<
    
    -- Editboxes / Bets
    if tableLocked == true then
        player5MainBetEditBox:SetText("")
        player5MainBetEditBox:Enable()
        player5PPBetEditBox:SetText("")
        player5PPBetEditBox:Enable()
        player5213BetEditBox:SetText("")
        player5213BetEditBox:Enable()
    else
        player5MainBetEditBox:SetText("")
        player5MainBetEditBox:Enable()
        player5PPBetEditBox:SetText("")
        player5PPBetEditBox:Enable()
        player5213BetEditBox:SetText("")
        player5213BetEditBox:Enable()
        player5ConfirmMainBetButton:Enable()
        player5ConfirmPPBetButton:Enable()
        player5Confirm213BetButton:Enable()
        player5PreloadBetButton:Enable()
    end
    -- Standard Buttons
    if playerName == unitName5 then
        player5MainBetEditBox:Show()
        player5ConfirmMainBetButton:Show()
        playerFrame.player5HitButton:Show()
        playerFrame.player5StandButton:Show()
        playerFrame.player5DoubleButton:Show()
        playerFrame.player5SplitButton:Show()
        playerFrame.player5InsuranceYesButton:Hide()
        playerFrame.player5InsuranceNoButton:Hide()
        playerFrame.player5InsuranceTitle:Hide()
        playerFrame.player5InsuranceSubtitle:Hide()
        playerFrame.player5DealNowButton:Show()
        playerFrame.player5DealNowButton:Disable()
    end
    playerFrame.player5HitButton:Disable()
    playerFrame.player5StandButton:Disable()
    playerFrame.player5DoubleButton:Disable()
    playerFrame.player5SplitButton:Disable()
    playerFrame.player5InsuranceYesButton:Disable()
    playerFrame.player5InsuranceNoButton:Disable()
    -- Bet Amount Labels
    player5MainBetAmount:Hide()
    player5MainBetAmount:SetTextColor(1, 1, 1)
    player5SplitH1BetAmount:Hide()
    player5SplitH1BetAmount:SetTextColor(1, 1, 1)
    player5SplitH2BetAmount:Hide()
    player5SplitH2BetAmount:SetTextColor(1, 1, 1)
    player5PPBetAmount:Hide()
    player5PPBetAmount:SetTextColor(1, 1, 1)
    player5PPBetAmount:SetPoint("CENTER", playerFrame, -328, 154)
    player5213BetAmount:Hide()
    player5213BetAmount:SetTextColor(1, 1, 1)
    player5213BetAmount:SetPoint("CENTER", playerFrame, -263, 56)
    playerFrame.player5InsuranceBetAmount:SetText("")
    playerFrame.player5InsuranceBetAmount:Hide()
    -- Coins Images
    playerFrame.player5MainBetCoins:Hide()
    playerFrame.player5NormalWinCoins:Hide()
    playerFrame.player5SplitHand2Coins:Hide()
    playerFrame.player5SplitHand2DoubleCoins:Hide()
    playerFrame.player5SplitHand2NormalWinCoins:Hide()
    playerFrame.player5SplitHand1Coins:Hide()
    playerFrame.player5SplitHand1DoubleCoins:Hide()
    playerFrame.player5SplitHand1NormalWinCoins:Hide()
    playerFrame.player5BJWinCoins:Hide()
    playerFrame.player5SplitHand2BJWinCoins:Hide()
    playerFrame.player5SplitHand1BJWinCoins:Hide()
    playerFrame.player5DoubleBetCoins:Hide()
    playerFrame.player5PPBetCoins:Hide()
    playerFrame.player5213BetCoins:Hide()
    playerFrame.player5PPWinCoins:Hide()
    playerFrame.player5213WinCoins:Hide()
    -- Insurance Icons
    player5InsuranceYesIcon:Hide()
    player5InsuranceNoIcon:Hide()
    -- Split Buttons & Editboxes
    playerFrame.player5SplitH1Title:Hide()
    playerFrame.player5SplitH2Title:Hide()
    player5SplitH1EditBox:Hide()
    player5SplitH2EditBox:Hide()
    playerFrame.player5HitButtonSplitH1:Hide()
    playerFrame.player5StandButtonSplitH1:Hide()
    playerFrame.player5DoubleButtonSplitH1:Hide()
    playerFrame.player5HitButtonSplitH2:Hide()
    playerFrame.player5StandButtonSplitH2:Hide()
    playerFrame.player5DoubleButtonSplitH2:Hide()
    -- Card Total Text
    playerFrame.player5CardTotalText:SetTextColor(1, 1, 1)
    playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 1, 1)
    playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 1, 1)
    -- Card Images / Filenames
    player5MainCardName1 = nil
    player5MainCardName2 = nil
    player5MainCardName3 = nil
    player5MainCardName4 = nil
    player5MainCardName5 = nil
    player5MainCardName6 = nil
    player5MainCardName7 = nil
    player5MainCardFileName1 = nil
    player5MainCardFileName2 = nil
    player5MainCardFileName3 = nil
    player5MainCardFileName4 = nil
    player5MainCardFileName5 = nil
    player5MainCardFileName6 = nil
    player5MainCardFileName7 = nil
    player5H1CardName1 = nil
    player5H1CardName2 = nil
    player5H1CardName3 = nil
    player5H1CardName4 = nil
    player5H1CardName5 = nil
    player5H1CardName6 = nil
    player5H1CardName7 = nil
    player5H1CardFileName1 = nil
    player5H1CardFileName2 = nil
    player5H1CardFileName3 = nil
    player5H1CardFileName4 = nil
    player5H1CardFileName5 = nil
    player5H1CardFileName6 = nil
    player5H1CardFileName7 = nil
    player5H2CardName1 = nil
    player5H2CardName2 = nil
    player5H2CardName3 = nil
    player5H2CardName4 = nil
    player5H2CardName5 = nil
    player5H2CardName6 = nil
    player5H2CardName7 = nil
    player5H2CardFileName1 = nil
    player5H2CardFileName2 = nil
    player5H2CardFileName3 = nil
    player5H2CardFileName4 = nil
    player5H2CardFileName5 = nil
    player5H2CardFileName6 = nil
    player5H2CardFileName7 = nil
    -- Timers
    timerFrame.player5TimerText:SetText("")
    timerFrame.player5TimerText:Hide()
    -- Variables
    player5NumberOfCards = 0
    player5NumberOfCardsH1 = 0
    player5NumberOfCardsH2 = 0
    player5SessionWin = 0
    player5DoubleToggle = false
    player5DoubleHand1Toggle = false
    player5DoubleHand2Toggle = false
    player5SplitToggle = false
    player5PPSideBetWin = false
    player5213SideBetWin = false
    player5Active = false
    player5SessionWinCalled = false

    if player5dealtCardsFrame:IsShown() then
        player5dealtCardsFrame.notStartedYetText:Show()
    end




    -- >>> DEALER <<<
    -- >>> DEALER <<<
    -- >>> DEALER <<<

    -- Card Total
    playerFrame.dealerCardTotalText:SetTextColor(1, 1, 1)
    -- Card Images / Filenames
    dealerCardName1 = nil
    dealerCardName2 = nil
    dealerCardName3 = nil
    dealerCardName4 = nil
    dealerCardName5 = nil
    dealerCardName6 = nil
    dealerCardName7 = nil
    dealerCardFileName1 = nil
    dealerCardFileName2 = nil
    dealerCardFileName3 = nil
    dealerCardFileName4 = nil
    dealerCardFileName5 = nil
    dealerCardFileName6 = nil
    dealerCardFileName7 = nil
    -- Timers
    timerBetsFrame.timerTextBets:SetText("")
    timerBetsFrame.timerTextBets:Hide()
    timerBetsFrame:Hide()
    timerFrame:Hide()
    countdownDuration = 30
    -- Variables
    turn = 0
    gameRunning = false
    -- "Cards" Frame
    player1dealtCardsFrame.notStartedYetText:Show()
    if player1dealtCardsFrameSplitH1:IsShown() then
        player1dealtCardsFrameSplitH1:Hide()
        player1dealtCardsFrameSplitH1.playerH1CardsButton:Hide()
        player1dealtCardsFrameSplitH1.playerH2CardsButton:Hide()
        player1dealtCardsFrameSplitH2:Hide()
        player1dealtCardsFrameSplitH2.playerH1CardsButton:Hide()
        player1dealtCardsFrameSplitH2.playerH2CardsButton:Hide()
        player1dealtCardsFrame:Show()
        player1dealtCardsFrame.playerCardsButton:Show()
        player1dealtCardsFrame.notStartedYetText:Show()
    elseif player1dealtCardsFrameSplitH2:IsShown() then
        player1dealtCardsFrameSplitH1:Hide()
        player1dealtCardsFrameSplitH1.playerH1CardsButton:Hide()
        player1dealtCardsFrameSplitH2:Hide()
        player1dealtCardsFrameSplitH2.playerH1CardsButton:Hide()
        player1dealtCardsFrameSplitH2.playerH2CardsButton:Hide()
        player1dealtCardsFrame:Show()
        player1dealtCardsFrame.playerCardsButton:Show()
        player1dealtCardsFrame.notStartedYetText:Show()
    end
    -- "sideBetWInFrame"
    sideBetWinFramePP:Hide()
    sideBetWinFrame213:Hide()
    sideBetWinFramePP.title:Hide()
    sideBetWinFrame213.title:Hide()
    sideBetWinFramePP.PPtext:Hide()
    sideBetWinFrame213.t213text:Hide()
    sideBetWinFramePP.MixedPairText:Hide()
    sideBetWinFramePP.ColouredPairText:Hide()
    sideBetWinFramePP.PerfectPairText:Hide()
    sideBetWinFrame213.FlushText:Hide()
    sideBetWinFrame213.StraightText:Hide()
    sideBetWinFrame213.ThreeOfAKindText:Hide()
    sideBetWinFrame213.StraightFlushText:Hide()
    sideBetWinFrame213.SuitedThreeOfAKindText:Hide()
    sideBetWinFramePP.player1PPCardImage1:Hide()
    sideBetWinFramePP.player1PPCardImage2:Hide()
    sideBetWinFrame213.player1213CardImage1:Hide()
    sideBetWinFrame213.player1213CardImage2:Hide()
    sideBetWinFrame213.dealer213CardImage1:Hide()
    sideBetWinFrame213.PlusSymbol:Hide()

    playerFrame.player1TurnArrow:Hide()
    playerFrame.player2TurnArrow:Hide()
    playerFrame.player3TurnArrow:Hide()
    playerFrame.player4TurnArrow:Hide()
    playerFrame.player5TurnArrow:Hide()

end






-- Function to remove card textures
function RemoveCardTextures()
    for i = 1, #drawnCards do
        drawnCards[i]:Hide() -- Hide the card texture
        drawnCards[i]:SetTexture(nil)  -- Set the texture to nil
    end

    if player1NewCardImage1 then
        player1NewCardImage1:Hide()
    end
    if player1NewCardImage2 then
        player1NewCardImage2:Hide()
    end
    if player2NewCardImage1 then
        player2NewCardImage1:Hide()
    end
    if player2NewCardImage2 then
        player2NewCardImage2:Hide()
    end
    if player3NewCardImage1 then
        player3NewCardImage1:Hide()
    end
    if player3NewCardImage2 then
        player3NewCardImage2:Hide()
    end
    if player4NewCardImage1 then
        player4NewCardImage1:Hide()
    end
    if player4NewCardImage2 then
        player4NewCardImage2:Hide()
    end
    if player5NewCardImage1 then
        player5NewCardImage1:Hide()
    end
    if player5NewCardImage2 then
        player5NewCardImage2:Hide()
    end

    drawnCards = {} -- Reset the table of card textures
    dealtCards = {}

    playerFrame.player1CardTotalText:Hide()
    playerFrame.player1SplitHand1CardTotalText:Hide()
    playerFrame.player1SplitHand2CardTotalText:Hide()
    playerFrame.player2CardTotalText:Hide()
    playerFrame.player2SplitHand1CardTotalText:Hide()
    playerFrame.player2SplitHand2CardTotalText:Hide()
    playerFrame.player3CardTotalText:Hide()
    playerFrame.player3SplitHand1CardTotalText:Hide()
    playerFrame.player3SplitHand2CardTotalText:Hide()
    playerFrame.player4CardTotalText:Hide()
    playerFrame.player4SplitHand1CardTotalText:Hide()
    playerFrame.player4SplitHand2CardTotalText:Hide()
    playerFrame.player5CardTotalText:Hide()
    playerFrame.player5SplitHand1CardTotalText:Hide()
    playerFrame.player5SplitHand2CardTotalText:Hide()
    playerFrame.dealerCardTotalText:Hide()

    playerFrame.player1CardTotalText:SetText("")
    playerFrame.player1SplitHand1CardTotalText:SetText("")
    playerFrame.player1SplitHand2CardTotalText:SetText("")
    playerFrame.player2CardTotalText:SetText("")
    playerFrame.player2SplitHand1CardTotalText:SetText("")
    playerFrame.player2SplitHand2CardTotalText:SetText("")
    playerFrame.player3CardTotalText:SetText("")
    playerFrame.player3SplitHand1CardTotalText:SetText("")
    playerFrame.player3SplitHand2CardTotalText:SetText("")
    playerFrame.player4CardTotalText:SetText("")
    playerFrame.player4SplitHand1CardTotalText:SetText("")
    playerFrame.player4SplitHand2CardTotalText:SetText("")
    playerFrame.player5CardTotalText:SetText("")
    playerFrame.player5SplitHand1CardTotalText:SetText("")
    playerFrame.player5SplitHand2CardTotalText:SetText("")

    -- Reset Dealt Cards Frame
    player1dealtCardsFrame.player1MainCardImage1:Hide()
    player1dealtCardsFrame.playerFirstCardText:Hide()
    player1dealtCardsFrame.player1MainCardImage2:Hide()
    player1dealtCardsFrame.playerSecondCardText:Hide()
    player1dealtCardsFrame.player1MainCardImage3:Hide()
    player1dealtCardsFrame.playerThirdCardText:Hide()
    player1dealtCardsFrame.player1MainCardImage4:Hide()
    player1dealtCardsFrame.playerFourthCardText:Hide()
    player1dealtCardsFrame.player1MainCardImage5:Hide()
    player1dealtCardsFrame.playerFifthCardText:Hide()
    player1dealtCardsFrame.player1MainCardImage6:Hide()
    player1dealtCardsFrame.playerSixthCardText:Hide()
    player1dealtCardsFrame.player1MainCardImage7:Hide()
    player1dealtCardsFrame.playerSeventhCardText:Hide()

    player1dealtCardsFrameSplitH1.player1H1CardImage1:Hide()
    player1dealtCardsFrameSplitH1.playerFirstCardText:Hide()
    player1dealtCardsFrameSplitH1.player1H1CardImage2:Hide()
    player1dealtCardsFrameSplitH1.playerSecondCardText:Hide()
    player1dealtCardsFrameSplitH1.player1H1CardImage3:Hide()
    player1dealtCardsFrameSplitH1.playerThirdCardText:Hide()
    player1dealtCardsFrameSplitH1.player1H1CardImage4:Hide()
    player1dealtCardsFrameSplitH1.playerFourthCardText:Hide()
    player1dealtCardsFrameSplitH1.player1H1CardImage5:Hide()
    player1dealtCardsFrameSplitH1.playerFifthCardText:Hide()
    player1dealtCardsFrameSplitH1.player1H1CardImage6:Hide()
    player1dealtCardsFrameSplitH1.playerSixthCardText:Hide()
    player1dealtCardsFrameSplitH1.player1H1CardImage7:Hide()
    player1dealtCardsFrameSplitH1.playerSeventhCardText:Hide()

    player1dealtCardsFrameSplitH2.player1H2CardImage1:Hide()
    player1dealtCardsFrameSplitH2.playerFirstCardText:Hide()
    player1dealtCardsFrameSplitH2.player1H2CardImage2:Hide()
    player1dealtCardsFrameSplitH2.playerSecondCardText:Hide()
    player1dealtCardsFrameSplitH2.player1H2CardImage3:Hide()
    player1dealtCardsFrameSplitH2.playerThirdCardText:Hide()
    player1dealtCardsFrameSplitH2.player1H2CardImage4:Hide()
    player1dealtCardsFrameSplitH2.playerFourthCardText:Hide()
    player1dealtCardsFrameSplitH2.player1H2CardImage5:Hide()
    player1dealtCardsFrameSplitH2.playerFifthCardText:Hide()
    player1dealtCardsFrameSplitH2.player1H2CardImage6:Hide()
    player1dealtCardsFrameSplitH2.playerSixthCardText:Hide()
    player1dealtCardsFrameSplitH2.player1H2CardImage7:Hide()
    player1dealtCardsFrameSplitH2.playerSeventhCardText:Hide()

    player2dealtCardsFrame.player2MainCardImage1:Hide()
    player2dealtCardsFrame.playerFirstCardText:Hide()
    player2dealtCardsFrame.player2MainCardImage2:Hide()
    player2dealtCardsFrame.playerSecondCardText:Hide()
    player2dealtCardsFrame.player2MainCardImage3:Hide()
    player2dealtCardsFrame.playerThirdCardText:Hide()
    player2dealtCardsFrame.player2MainCardImage4:Hide()
    player2dealtCardsFrame.playerFourthCardText:Hide()
    player2dealtCardsFrame.player2MainCardImage5:Hide()
    player2dealtCardsFrame.playerFifthCardText:Hide()
    player2dealtCardsFrame.player2MainCardImage6:Hide()
    player2dealtCardsFrame.playerSixthCardText:Hide()
    player2dealtCardsFrame.player2MainCardImage7:Hide()
    player2dealtCardsFrame.playerSeventhCardText:Hide()

    player2dealtCardsFrameSplitH1.player2H1CardImage1:Hide()
    player2dealtCardsFrameSplitH1.playerFirstCardText:Hide()
    player2dealtCardsFrameSplitH1.player2H1CardImage2:Hide()
    player2dealtCardsFrameSplitH1.playerSecondCardText:Hide()
    player2dealtCardsFrameSplitH1.player2H1CardImage3:Hide()
    player2dealtCardsFrameSplitH1.playerThirdCardText:Hide()
    player2dealtCardsFrameSplitH1.player2H1CardImage4:Hide()
    player2dealtCardsFrameSplitH1.playerFourthCardText:Hide()
    player2dealtCardsFrameSplitH1.player2H1CardImage5:Hide()
    player2dealtCardsFrameSplitH1.playerFifthCardText:Hide()
    player2dealtCardsFrameSplitH1.player2H1CardImage6:Hide()
    player2dealtCardsFrameSplitH1.playerSixthCardText:Hide()
    player2dealtCardsFrameSplitH1.player2H1CardImage7:Hide()
    player2dealtCardsFrameSplitH1.playerSeventhCardText:Hide()

    player2dealtCardsFrameSplitH2.player2H2CardImage1:Hide()
    player2dealtCardsFrameSplitH2.playerFirstCardText:Hide()
    player2dealtCardsFrameSplitH2.player2H2CardImage2:Hide()
    player2dealtCardsFrameSplitH2.playerSecondCardText:Hide()
    player2dealtCardsFrameSplitH2.player2H2CardImage3:Hide()
    player2dealtCardsFrameSplitH2.playerThirdCardText:Hide()
    player2dealtCardsFrameSplitH2.player2H2CardImage4:Hide()
    player2dealtCardsFrameSplitH2.playerFourthCardText:Hide()
    player2dealtCardsFrameSplitH2.player2H2CardImage5:Hide()
    player2dealtCardsFrameSplitH2.playerFifthCardText:Hide()
    player2dealtCardsFrameSplitH2.player2H2CardImage6:Hide()
    player2dealtCardsFrameSplitH2.playerSixthCardText:Hide()
    player2dealtCardsFrameSplitH2.player2H2CardImage7:Hide()
    player2dealtCardsFrameSplitH2.playerSeventhCardText:Hide()

    player3dealtCardsFrame.player3MainCardImage1:Hide()
    player3dealtCardsFrame.playerFirstCardText:Hide()
    player3dealtCardsFrame.player3MainCardImage2:Hide()
    player3dealtCardsFrame.playerSecondCardText:Hide()
    player3dealtCardsFrame.player3MainCardImage3:Hide()
    player3dealtCardsFrame.playerThirdCardText:Hide()
    player3dealtCardsFrame.player3MainCardImage4:Hide()
    player3dealtCardsFrame.playerFourthCardText:Hide()
    player3dealtCardsFrame.player3MainCardImage5:Hide()
    player3dealtCardsFrame.playerFifthCardText:Hide()
    player3dealtCardsFrame.player3MainCardImage6:Hide()
    player3dealtCardsFrame.playerSixthCardText:Hide()
    player3dealtCardsFrame.player3MainCardImage7:Hide()
    player3dealtCardsFrame.playerSeventhCardText:Hide()

    player3dealtCardsFrameSplitH1.player3H1CardImage1:Hide()
    player3dealtCardsFrameSplitH1.playerFirstCardText:Hide()
    player3dealtCardsFrameSplitH1.player3H1CardImage2:Hide()
    player3dealtCardsFrameSplitH1.playerSecondCardText:Hide()
    player3dealtCardsFrameSplitH1.player3H1CardImage3:Hide()
    player3dealtCardsFrameSplitH1.playerThirdCardText:Hide()
    player3dealtCardsFrameSplitH1.player3H1CardImage4:Hide()
    player3dealtCardsFrameSplitH1.playerFourthCardText:Hide()
    player3dealtCardsFrameSplitH1.player3H1CardImage5:Hide()
    player3dealtCardsFrameSplitH1.playerFifthCardText:Hide()
    player3dealtCardsFrameSplitH1.player3H1CardImage6:Hide()
    player3dealtCardsFrameSplitH1.playerSixthCardText:Hide()
    player3dealtCardsFrameSplitH1.player3H1CardImage7:Hide()
    player3dealtCardsFrameSplitH1.playerSeventhCardText:Hide()

    player3dealtCardsFrameSplitH2.player3H2CardImage1:Hide()
    player3dealtCardsFrameSplitH2.playerFirstCardText:Hide()
    player3dealtCardsFrameSplitH2.player3H2CardImage2:Hide()
    player3dealtCardsFrameSplitH2.playerSecondCardText:Hide()
    player3dealtCardsFrameSplitH2.player3H2CardImage3:Hide()
    player3dealtCardsFrameSplitH2.playerThirdCardText:Hide()
    player3dealtCardsFrameSplitH2.player3H2CardImage4:Hide()
    player3dealtCardsFrameSplitH2.playerFourthCardText:Hide()
    player3dealtCardsFrameSplitH2.player3H2CardImage5:Hide()
    player3dealtCardsFrameSplitH2.playerFifthCardText:Hide()
    player3dealtCardsFrameSplitH2.player3H2CardImage6:Hide()
    player3dealtCardsFrameSplitH2.playerSixthCardText:Hide()
    player3dealtCardsFrameSplitH2.player3H2CardImage7:Hide()
    player3dealtCardsFrameSplitH2.playerSeventhCardText:Hide()

    player4dealtCardsFrame.player4MainCardImage1:Hide()
    player4dealtCardsFrame.playerFirstCardText:Hide()
    player4dealtCardsFrame.player4MainCardImage2:Hide()
    player4dealtCardsFrame.playerSecondCardText:Hide()
    player4dealtCardsFrame.player4MainCardImage3:Hide()
    player4dealtCardsFrame.playerThirdCardText:Hide()
    player4dealtCardsFrame.player4MainCardImage4:Hide()
    player4dealtCardsFrame.playerFourthCardText:Hide()
    player4dealtCardsFrame.player4MainCardImage5:Hide()
    player4dealtCardsFrame.playerFifthCardText:Hide()
    player4dealtCardsFrame.player4MainCardImage6:Hide()
    player4dealtCardsFrame.playerSixthCardText:Hide()
    player4dealtCardsFrame.player4MainCardImage7:Hide()
    player4dealtCardsFrame.playerSeventhCardText:Hide()

    player4dealtCardsFrameSplitH1.player4H1CardImage1:Hide()
    player4dealtCardsFrameSplitH1.playerFirstCardText:Hide()
    player4dealtCardsFrameSplitH1.player4H1CardImage2:Hide()
    player4dealtCardsFrameSplitH1.playerSecondCardText:Hide()
    player4dealtCardsFrameSplitH1.player4H1CardImage3:Hide()
    player4dealtCardsFrameSplitH1.playerThirdCardText:Hide()
    player4dealtCardsFrameSplitH1.player4H1CardImage4:Hide()
    player4dealtCardsFrameSplitH1.playerFourthCardText:Hide()
    player4dealtCardsFrameSplitH1.player4H1CardImage5:Hide()
    player4dealtCardsFrameSplitH1.playerFifthCardText:Hide()
    player4dealtCardsFrameSplitH1.player4H1CardImage6:Hide()
    player4dealtCardsFrameSplitH1.playerSixthCardText:Hide()
    player4dealtCardsFrameSplitH1.player4H1CardImage7:Hide()
    player4dealtCardsFrameSplitH1.playerSeventhCardText:Hide()

    player4dealtCardsFrameSplitH2.player4H2CardImage1:Hide()
    player4dealtCardsFrameSplitH2.playerFirstCardText:Hide()
    player4dealtCardsFrameSplitH2.player4H2CardImage2:Hide()
    player4dealtCardsFrameSplitH2.playerSecondCardText:Hide()
    player4dealtCardsFrameSplitH2.player4H2CardImage3:Hide()
    player4dealtCardsFrameSplitH2.playerThirdCardText:Hide()
    player4dealtCardsFrameSplitH2.player4H2CardImage4:Hide()
    player4dealtCardsFrameSplitH2.playerFourthCardText:Hide()
    player4dealtCardsFrameSplitH2.player4H2CardImage5:Hide()
    player4dealtCardsFrameSplitH2.playerFifthCardText:Hide()
    player4dealtCardsFrameSplitH2.player4H2CardImage6:Hide()
    player4dealtCardsFrameSplitH2.playerSixthCardText:Hide()
    player4dealtCardsFrameSplitH2.player4H2CardImage7:Hide()
    player4dealtCardsFrameSplitH2.playerSeventhCardText:Hide()

    player5dealtCardsFrame.player5MainCardImage1:Hide()
    player5dealtCardsFrame.playerFirstCardText:Hide()
    player5dealtCardsFrame.player5MainCardImage2:Hide()
    player5dealtCardsFrame.playerSecondCardText:Hide()
    player5dealtCardsFrame.player5MainCardImage3:Hide()
    player5dealtCardsFrame.playerThirdCardText:Hide()
    player5dealtCardsFrame.player5MainCardImage4:Hide()
    player5dealtCardsFrame.playerFourthCardText:Hide()
    player5dealtCardsFrame.player5MainCardImage5:Hide()
    player5dealtCardsFrame.playerFifthCardText:Hide()
    player5dealtCardsFrame.player5MainCardImage6:Hide()
    player5dealtCardsFrame.playerSixthCardText:Hide()
    player5dealtCardsFrame.player5MainCardImage7:Hide()
    player5dealtCardsFrame.playerSeventhCardText:Hide()

    player5dealtCardsFrameSplitH1.player5H1CardImage1:Hide()
    player5dealtCardsFrameSplitH1.playerFirstCardText:Hide()
    player5dealtCardsFrameSplitH1.player5H1CardImage2:Hide()
    player5dealtCardsFrameSplitH1.playerSecondCardText:Hide()
    player5dealtCardsFrameSplitH1.player5H1CardImage3:Hide()
    player5dealtCardsFrameSplitH1.playerThirdCardText:Hide()
    player5dealtCardsFrameSplitH1.player5H1CardImage4:Hide()
    player5dealtCardsFrameSplitH1.playerFourthCardText:Hide()
    player5dealtCardsFrameSplitH1.player5H1CardImage5:Hide()
    player5dealtCardsFrameSplitH1.playerFifthCardText:Hide()
    player5dealtCardsFrameSplitH1.player5H1CardImage6:Hide()
    player5dealtCardsFrameSplitH1.playerSixthCardText:Hide()
    player5dealtCardsFrameSplitH1.player5H1CardImage7:Hide()
    player5dealtCardsFrameSplitH1.playerSeventhCardText:Hide()

    player5dealtCardsFrameSplitH2.player5H2CardImage1:Hide()
    player5dealtCardsFrameSplitH2.playerFirstCardText:Hide()
    player5dealtCardsFrameSplitH2.player5H2CardImage2:Hide()
    player5dealtCardsFrameSplitH2.playerSecondCardText:Hide()
    player5dealtCardsFrameSplitH2.player5H2CardImage3:Hide()
    player5dealtCardsFrameSplitH2.playerThirdCardText:Hide()
    player5dealtCardsFrameSplitH2.player5H2CardImage4:Hide()
    player5dealtCardsFrameSplitH2.playerFourthCardText:Hide()
    player5dealtCardsFrameSplitH2.player5H2CardImage5:Hide()
    player5dealtCardsFrameSplitH2.playerFifthCardText:Hide()
    player5dealtCardsFrameSplitH2.player5H2CardImage6:Hide()
    player5dealtCardsFrameSplitH2.playerSixthCardText:Hide()
    player5dealtCardsFrameSplitH2.player5H2CardImage7:Hide()
    player5dealtCardsFrameSplitH2.playerSeventhCardText:Hide()

    -- Reset DealerTotal
    playerFrame.dealerCardTotalText:SetText("")
end
-- Function to get the card image file name from the card name
function GetCardFileName(cardName)
    for fileName, name in pairs(cardNames) do
        if name == cardName then
            return fileName
        end
    end
end








-- Event register for raid chat messages
eventFrame = CreateFrame("Frame")
eventFrame:RegisterEvent("CHAT_MSG_RAID")
eventFrame:SetScript("OnEvent", function(self, event, message, sender)

    AceValues = {
        ["1 or 11"] = "11",
        ["2 or 12"] = "12",
        ["3 or 13"] = "13",
        ["4 or 14"] = "14",
        ["5 or 15"] = "15",
        ["6 or 16"] = "16",
        ["7 or 17"] = "17",
        ["8 or 18"] = "18",
        ["9 or 19"] = "19",
        ["10 or 20"] = "20"
    }

    player1BeforeStandValue = playerFrame.player1CardTotalText:GetText()
    player1AfterStandValue = AceValues[player1BeforeStandValue]
    player1SplitHand1BeforeStandValue = playerFrame.player1SplitHand1CardTotalText:GetText()
    player1SplitHand1AfterStandValue = AceValues[player1SplitHand1BeforeStandValue]
    player1SplitHand2BeforeStandValue = playerFrame.player1SplitHand2CardTotalText:GetText()
    player1SplitHand2AfterStandValue = AceValues[player1SplitHand2BeforeStandValue]

    player2BeforeStandValue = playerFrame.player2CardTotalText:GetText()
    player2AfterStandValue = AceValues[player2BeforeStandValue]
    player2SplitHand1BeforeStandValue = playerFrame.player2SplitHand1CardTotalText:GetText()
    player2SplitHand1AfterStandValue = AceValues[player2SplitHand1BeforeStandValue]
    player2SplitHand2BeforeStandValue = playerFrame.player2SplitHand2CardTotalText:GetText()
    player2SplitHand2AfterStandValue = AceValues[player2SplitHand2BeforeStandValue]

    player3BeforeStandValue = playerFrame.player3CardTotalText:GetText()
    player3AfterStandValue = AceValues[player3BeforeStandValue]
    player3SplitHand1BeforeStandValue = playerFrame.player3SplitHand1CardTotalText:GetText()
    player3SplitHand1AfterStandValue = AceValues[player3SplitHand1BeforeStandValue]
    player3SplitHand2BeforeStandValue = playerFrame.player3SplitHand2CardTotalText:GetText()
    player3SplitHand2AfterStandValue = AceValues[player3SplitHand2BeforeStandValue]

    player4BeforeStandValue = playerFrame.player4CardTotalText:GetText()
    player4AfterStandValue = AceValues[player4BeforeStandValue]
    player4SplitHand1BeforeStandValue = playerFrame.player4SplitHand1CardTotalText:GetText()
    player4SplitHand1AfterStandValue = AceValues[player4SplitHand1BeforeStandValue]
    player4SplitHand2BeforeStandValue = playerFrame.player4SplitHand2CardTotalText:GetText()
    player4SplitHand2AfterStandValue = AceValues[player4SplitHand2BeforeStandValue]

    player5BeforeStandValue = playerFrame.player5CardTotalText:GetText()
    player5AfterStandValue = AceValues[player5BeforeStandValue]
    player5SplitHand1BeforeStandValue = playerFrame.player5SplitHand1CardTotalText:GetText()
    player5SplitHand1AfterStandValue = AceValues[player5SplitHand1BeforeStandValue]
    player5SplitHand2BeforeStandValue = playerFrame.player5SplitHand2CardTotalText:GetText()
    player5SplitHand2AfterStandValue = AceValues[player5SplitHand2BeforeStandValue]

    if string.find(message, "{circle}%s+(%S+)%s+has%s+sat%s+down%s+in%s+Seat%s+1%.?") then
        player1Name = string.match(message, "{circle}%s+(%S+)%s+has%s+sat%s+down%s+in%s+Seat%s+1%.?")
        unitName1 = player1Name
        if unitName1 == unitName2 then
            unitName2 = nil
        elseif unitName1 == unitName3 then
            unitName3 = nil
        elseif unitName1 == unitName4 then
            unitName4 = nil
        elseif unitName1 == unitName5 then
            unitName5 = nil
        end
        playerFrame.player1Name:SetText(player1Name)
        playerFrame.takeSeat1Button:Disable()

        -- If the player has banking information stored, retrieve it
        if playerBankingInfo[player1Name] then
            bankingInfo = playerBankingInfo[player1Name]
            player1BankingTotalWagered = bankingInfo.totalWagered
            historyFrame.player1totalWageredAmount:SetText(player1BankingTotalWagered .. " G")
            player1BankingTotalWon = bankingInfo.totalWon
            historyFrame.player1totalWonAmount:SetText(player1BankingTotalWon .. " G")
            player1BankingTotalLost = bankingInfo.totalLost
            historyFrame.player1totalLostAmount:SetText(player1BankingTotalLost .. " G")
            player1BankingTotalProfit = bankingInfo.totalProfit
            historyFrame.player1ProfitAmount:SetText(player1BankingTotalProfit .. " G")
            if player1BankingTotalProfit > 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            elseif player1BankingTotalProfit == 0 then
                historyFrame.player1ProfitAmount:SetTextColor(1, 1, 1)
            elseif player1BankingTotalProfit < 0 then
                historyFrame.player1ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
            player1BankingBankrollTable = bankingInfo.bankrollTable
            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1BankingBankrollTable .. " G")
            player1BankingBankrollCashDesk = bankingInfo.bankrollCashDesk
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1BankingBankrollCashDesk .. " G")
        
        else
            -- Initialize banking information if not found
            player1totalBetAmount = 0
            player1totalWin = 0
            player1totalLoss = 0
            player1totalProfit = 0
            player1TotalBankrollAmount = 0
        end
    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+left%s+Seat%s+1%.?") then
        playerFrame.player1Name:SetText("Seat Empty")
        if playerFrame.player2HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player4HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
            playerFrame.takeSeat1Button:Disable()
        else
            playerFrame.takeSeat1Button:Enable()
        end

        player1Hotstreak = 0
        player1HotstreakImage1:Hide()
        player1HotstreakImage2:Hide()
        player1HotstreakImage3:Hide()
        player1HotstreakImage4:Hide()
        player1HotstreakImage5:Hide()
        player1HotstreakImage6:Hide()
        player1HotstreakImage7:Hide()
        player1HotstreakImage8:Hide()
        player1HotstreakImage9:Hide()
        player1HotstreakImage10:Hide()
        player1HotstreakImage11:Hide()
        player1HotstreakImage12:Hide()
        player1HotstreakImage13:Hide()
        player1HotstreakImage14:Hide()
        player1HotstreakImage15:Hide()

        historyFrame.player1totalWageredAmount:SetText("0 G")
        historyFrame.player1totalWonAmount:SetText("0 G")
        historyFrame.player1totalLostAmount:SetText("0 G")
        historyFrame.player1ProfitAmount:SetText("0 G")
        historyFrame.player1ProfitAmount:SetTextColor(1, 1, 1)

        player1totalBetAmount = 0
        player1totalWin = 0
        player1totalLoss = 0
        player1totalProfit = 0
        player1TotalBankrollAmount = 0

        -- Reset banking information for the leaving player
        unitName1 = nil
        player1Name = nil
    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+sat%s+down%s+in%s+Seat%s+2%.?") then
        player2Name = string.match(message, "{circle}%s+(%S+)%s+has%s+sat%s+down%s+in%s+Seat%s+2%.?")
        unitName2 = player2Name
        if unitName2 == unitName1 then
            unitName1 = nil
        elseif unitName2 == unitName3 then
            unitName3 = nil
        elseif unitName2 == unitName4 then
            unitName4 = nil
        elseif unitName2 == unitName5 then
            unitName5 = nil
        end
        playerFrame.player2Name:SetText(player2Name)
        playerFrame.takeSeat2Button:Disable()

        -- If the player has banking information stored, retrieve it
        if playerBankingInfo[player2Name] then
            bankingInfo = playerBankingInfo[player2Name]
            player2BankingTotalWagered = bankingInfo.totalWagered
            historyFrame.player2totalWageredAmount:SetText(player2BankingTotalWagered .. " G")
            player2BankingTotalWon = bankingInfo.totalWon
            historyFrame.player2totalWonAmount:SetText(player2BankingTotalWon .. " G")
            player2BankingTotalLost = bankingInfo.totalLost
            historyFrame.player2totalLostAmount:SetText(player2BankingTotalLost .. " G")
            player2BankingTotalProfit = bankingInfo.totalProfit
            historyFrame.player2ProfitAmount:SetText(player2BankingTotalProfit .. " G")
            if player2BankingTotalProfit > 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            elseif player2BankingTotalProfit == 0 then
                historyFrame.player2ProfitAmount:SetTextColor(1, 1, 1)
            elseif player2BankingTotalProfit < 0 then
                historyFrame.player2ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
            player2BankingBankrollTable = bankingInfo.bankrollTable
            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2BankingBankrollTable .. " G")
            player2BankingBankrollCashDesk = bankingInfo.bankrollCashDesk
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2BankingBankrollCashDesk .. " G")
        else
            -- Initialize banking information if not found
            player2totalBetAmount = 0
            player2totalWin = 0
            player2totalLoss = 0
            player2totalProfit = 0
            player2TotalBankrollAmount = 0
        end
    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+left%s+Seat%s+2%.?") then
        playerFrame.player2Name:SetText("Seat Empty")
        if playerFrame.player1HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player4HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
            playerFrame.takeSeat2Button:Disable()
        else
            playerFrame.takeSeat2Button:Enable()
        end

        player2Hotstreak = 0
        player2HotstreakImage1:Hide()
        player2HotstreakImage2:Hide()
        player2HotstreakImage3:Hide()
        player2HotstreakImage4:Hide()
        player2HotstreakImage5:Hide()
        player2HotstreakImage6:Hide()
        player2HotstreakImage7:Hide()
        player2HotstreakImage8:Hide()
        player2HotstreakImage9:Hide()
        player2HotstreakImage10:Hide()
        player2HotstreakImage11:Hide()
        player2HotstreakImage12:Hide()
        player2HotstreakImage13:Hide()
        player2HotstreakImage14:Hide()
        player2HotstreakImage15:Hide()

        wageredString = historyFrame.player2totalWageredAmount:GetText()
        wonString = historyFrame.player2totalWonAmount:GetText()
        lostString = historyFrame.player2totalLostAmount:GetText()
        profitString = historyFrame.player2ProfitAmount:GetText()
        bankrollString = bankrollFrame.player2TotalBankrollTableDisplay:GetText()

        wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
        wonAmount = tonumber(string.match(wonString, "(%d+)"))
        lostAmount = tonumber(string.match(lostString, "(%d+)"))
        profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

        -- Store banking information for the leaving player
        if wageredAmount then
            playerBankingInfo[player2Name] = {
                totalWagered = wageredAmount,
                totalWon = wonAmount,
                totalLost = lostAmount,
                totalProfit = profitAmount,
                bankrollTable = bankrollAmount,
                bankrollCashDesk = bankrollAmount
            }
        end

        historyFrame.player2totalWageredAmount:SetText("0 G")
        historyFrame.player2totalWonAmount:SetText("0 G")
        historyFrame.player2totalLostAmount:SetText("0 G")
        historyFrame.player2ProfitAmount:SetText("0 G")
        historyFrame.player2ProfitAmount:SetTextColor(1, 1, 1)

        player2totalBetAmount = 0
        player2totalWin = 0
        player2totalLoss = 0
        player2totalProfit = 0
        player2TotalBankrollAmount = 0

        -- Reset banking information for the leaving player
        unitName2 = nil
        player2Name = nil

    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+sat%s+down%s+in%s+Seat%s+3%.?") then
        player3Name = string.match(message, "{circle}%s+(%S+)%s+has%s+sat%s+down%s+in%s+Seat%s+3%.?")
        unitName3 = player3Name
        if unitName3 == unitName1 then
            unitName1 = nil
        elseif unitName3 == unitName2 then
            unitName2 = nil
        elseif unitName3 == unitName4 then
            unitName4 = nil
        elseif unitName3 == unitName5 then
            unitName5 = nil
        end
        playerFrame.player3Name:SetText(player3Name)
        playerFrame.takeSeat3Button:Disable()

        -- If the player has banking information stored, retrieve it
        if playerBankingInfo[player3Name] then
            bankingInfo = playerBankingInfo[player3Name]
            player3BankingTotalWagered = bankingInfo.totalWagered
            historyFrame.player3totalWageredAmount:SetText(player3BankingTotalWagered .. " G")
            player3BankingTotalWon = bankingInfo.totalWon
            historyFrame.player3totalWonAmount:SetText(player3BankingTotalWon .. " G")
            player3BankingTotalLost = bankingInfo.totalLost
            historyFrame.player3totalLostAmount:SetText(player3BankingTotalLost .. " G")
            player3BankingTotalProfit = bankingInfo.totalProfit
            historyFrame.player3ProfitAmount:SetText(player3BankingTotalProfit .. " G")
            if player3BankingTotalProfit > 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            elseif player3BankingTotalProfit == 0 then
                historyFrame.player3ProfitAmount:SetTextColor(1, 1, 1)
            elseif player3BankingTotalProfit < 0 then
                historyFrame.player3ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
            player3BankingBankrollTable = bankingInfo.bankrollTable
            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3BankingBankrollTable .. " G")
            player3BankingBankrollCashDesk = bankingInfo.bankrollCashDesk
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3BankingBankrollCashDesk .. " G")
        else
            -- Initialize banking information if not found
            player3totalBetAmount = 0
            player3totalWin = 0
            player3totalLoss = 0
            player3totalProfit = 0
            player3TotalBankrollAmount = 0
        end
    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+left%s+Seat%s+3%.?") then
        playerFrame.player3Name:SetText("Seat Empty")
        if playerFrame.player1HitButton:IsShown() or playerFrame.player2HitButton:IsShown() or playerFrame.player4HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
            playerFrame.takeSeat3Button:Disable()
        else
            playerFrame.takeSeat3Button:Enable()
        end

        player3Hotstreak = 0
        player3HotstreakImage1:Hide()
        player3HotstreakImage2:Hide()
        player3HotstreakImage3:Hide()
        player3HotstreakImage4:Hide()
        player3HotstreakImage5:Hide()
        player3HotstreakImage6:Hide()
        player3HotstreakImage7:Hide()
        player3HotstreakImage8:Hide()
        player3HotstreakImage9:Hide()
        player3HotstreakImage10:Hide()
        player3HotstreakImage11:Hide()
        player3HotstreakImage12:Hide()
        player3HotstreakImage13:Hide()
        player3HotstreakImage14:Hide()
        player3HotstreakImage15:Hide()

        wageredString = historyFrame.player3totalWageredAmount:GetText()
        wonString = historyFrame.player3totalWonAmount:GetText()
        lostString = historyFrame.player3totalLostAmount:GetText()
        profitString = historyFrame.player3ProfitAmount:GetText()
        bankrollString = bankrollFrame.player3TotalBankrollTableDisplay:GetText()

        wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
        wonAmount = tonumber(string.match(wonString, "(%d+)"))
        lostAmount = tonumber(string.match(lostString, "(%d+)"))
        profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

        -- Store banking information for the leaving player
        if wageredAmount then
            playerBankingInfo[player3Name] = {
                totalWagered = wageredAmount,
                totalWon = wonAmount,
                totalLost = lostAmount,
                totalProfit = profitAmount,
                bankrollTable = bankrollAmount,
                bankrollCashDesk = bankrollAmount
            }
        end

        historyFrame.player3totalWageredAmount:SetText("0 G")
        historyFrame.player3totalWonAmount:SetText("0 G")
        historyFrame.player3totalLostAmount:SetText("0 G")
        historyFrame.player3ProfitAmount:SetText("0 G")
        historyFrame.player3ProfitAmount:SetTextColor(1, 1, 1)

        player3totalBetAmount = 0
        player32totalWin = 0
        player3totalLoss = 0
        player3totalProfit = 0
        player3TotalBankrollAmount = 0

        -- Reset banking information for the leaving player
        unitName3 = nil
        player3Name = nil

    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+sat%s+down%s+in%s+Seat%s+4%.?") then
        player4Name = string.match(message, "{circle}%s+(%S+)%s+has%s+sat%s+down%s+in%s+Seat%s+4%.?")
        unitName4 = player4Name
        if unitName4 == unitName1 then
            unitName1 = nil
        elseif unitName4 == unitName2 then
            unitName2 = nil
        elseif unitName4 == unitName3 then
            unitName3 = nil
        elseif unitName4 == unitName5 then
            unitName5 = nil
        end
        playerFrame.player4Name:SetText(player4Name)
        playerFrame.takeSeat4Button:Disable()

        -- If the player has banking information stored, retrieve it
        if playerBankingInfo[player4Name] then
            bankingInfo = playerBankingInfo[player4Name]
            player4BankingTotalWagered = bankingInfo.totalWagered
            historyFrame.player4totalWageredAmount:SetText(player4BankingTotalWagered .. " G")
            player4BankingTotalWon = bankingInfo.totalWon
            historyFrame.player4totalWonAmount:SetText(player4BankingTotalWon .. " G")
            player4BankingTotalLost = bankingInfo.totalLost
            historyFrame.player4totalLostAmount:SetText(player4BankingTotalLost .. " G")
            player4BankingTotalProfit = bankingInfo.totalProfit
            historyFrame.player4ProfitAmount:SetText(player4BankingTotalProfit .. " G")
            if player4BankingTotalProfit > 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            elseif player4BankingTotalProfit == 0 then
                historyFrame.player4ProfitAmount:SetTextColor(1, 1, 1)
            elseif player4BankingTotalProfit < 0 then
                historyFrame.player4ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
            player4BankingBankrollTable = bankingInfo.bankrollTable
            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4BankingBankrollTable .. " G")
            player4BankingBankrollCashDesk = bankingInfo.bankrollCashDesk
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4BankingBankrollCashDesk .. " G")
        else
            -- Initialize banking information if not found
            player4totalBetAmount = 0
            player4totalWin = 0
            player4totalLoss = 0
            player4totalProfit = 0
            player4TotalBankrollAmount = 0
        end
    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+left%s+Seat%s+4%.?") then
        playerFrame.player4Name:SetText("Seat Empty")
        if playerFrame.player1HitButton:IsShown() or playerFrame.player2HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
            playerFrame.takeSeat4Button:Disable()
        else
            playerFrame.takeSeat4Button:Enable()
        end

        player4Hotstreak = 0
        player4HotstreakImage1:Hide()
        player4HotstreakImage2:Hide()
        player4HotstreakImage3:Hide()
        player4HotstreakImage4:Hide()
        player4HotstreakImage5:Hide()
        player4HotstreakImage6:Hide()
        player4HotstreakImage7:Hide()
        player4HotstreakImage8:Hide()
        player4HotstreakImage9:Hide()
        player4HotstreakImage10:Hide()
        player4HotstreakImage11:Hide()
        player4HotstreakImage12:Hide()
        player4HotstreakImage13:Hide()
        player4HotstreakImage14:Hide()
        player4HotstreakImage15:Hide()

        wageredString = historyFrame.player4totalWageredAmount:GetText()
        wonString = historyFrame.player4totalWonAmount:GetText()
        lostString = historyFrame.player4totalLostAmount:GetText()
        profitString = historyFrame.player4ProfitAmount:GetText()
        bankrollString = bankrollFrame.player4TotalBankrollTableDisplay:GetText()

        wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
        wonAmount = tonumber(string.match(wonString, "(%d+)"))
        lostAmount = tonumber(string.match(lostString, "(%d+)"))
        profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

        -- Store banking information for the leaving player
        if wageredAmount then
            playerBankingInfo[player4Name] = {
                totalWagered = wageredAmount,
                totalWon = wonAmount,
                totalLost = lostAmount,
                totalProfit = profitAmount,
                bankrollTable = bankrollAmount,
                bankrollCashDesk = bankrollAmount
            }
        end

        historyFrame.player4totalWageredAmount:SetText("0 G")
        historyFrame.player4totalWonAmount:SetText("0 G")
        historyFrame.player4totalLostAmount:SetText("0 G")
        historyFrame.player4ProfitAmount:SetText("0 G")
        historyFrame.player4ProfitAmount:SetTextColor(1, 1, 1)

        player4totalBetAmount = 0
        player4totalWin = 0
        player4totalLoss = 0
        player4totalProfit = 0
        player4TotalBankrollAmount = 0

        -- Reset banking information for the leaving player
        unitName4 = nil
        player4Name = nil

    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+sat%s+down%s+in%s+Seat%s+5%.?") then
        player5Name = string.match(message, "{circle}%s+(%S+)%s+has%s+sat%s+down%s+in%s+Seat%s+5%.?")
        unitName5 = player5Name
        if unitName5 == unitName1 then
            unitName1 = nil
        elseif unitName5 == unitName2 then
            unitName2 = nil
        elseif unitName5 == unitName3 then
            unitName3 = nil
        elseif unitName5 == unitName4 then
            unitName4 = nil
        end
        playerFrame.player5Name:SetText(player5Name)
        playerFrame.takeSeat5Button:Disable()

        -- If the player has banking information stored, retrieve it
        if playerBankingInfo[player5Name] then
            bankingInfo = playerBankingInfo[player5Name]
            player5BankingTotalWagered = bankingInfo.totalWagered
            historyFrame.player5totalWageredAmount:SetText(player5BankingTotalWagered .. " G")
            player5BankingTotalWon = bankingInfo.totalWon
            historyFrame.player5totalWonAmount:SetText(player5BankingTotalWon .. " G")
            player5BankingTotalLost = bankingInfo.totalLost
            historyFrame.player5totalLostAmount:SetText(player5BankingTotalLost .. " G")
            player5BankingTotalProfit = bankingInfo.totalProfit
            historyFrame.player5ProfitAmount:SetText(player5BankingTotalProfit .. " G")
            if player5BankingTotalProfit > 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.098, 0.878, 0.098)
            elseif player5BankingTotalProfit == 0 then
                historyFrame.player5ProfitAmount:SetTextColor(1, 1, 1)
            elseif player5BankingTotalProfit < 0 then
                historyFrame.player5ProfitAmount:SetTextColor(0.961, 0.306, 0.306)
            end
            player5BankingBankrollTable = bankingInfo.bankrollTable
            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5BankingBankrollTable .. " G")
            player5BankingBankrollCashDesk = bankingInfo.bankrollCashDesk
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5BankingBankrollCashDesk .. " G")
        else
            -- Initialize banking information if not found
            player5totalBetAmount = 0
            player5totalWin = 0
            player5totalLoss = 0
            player5totalProfit = 0
            player5TotalBankrollAmount = 0
        end
    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+left%s+Seat%s+5%.?") then
        playerFrame.player5Name:SetText("Seat Empty")
        if playerFrame.player1HitButton:IsShown() or playerFrame.player2HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player4HitButton:IsShown() then
            playerFrame.takeSeat5Button:Disable()
        else
            playerFrame.takeSeat5Button:Enable()
        end

        player5Hotstreak = 0
        player5HotstreakImage1:Hide()
        player5HotstreakImage2:Hide()
        player5HotstreakImage3:Hide()
        player5HotstreakImage4:Hide()
        player5HotstreakImage5:Hide()
        player5HotstreakImage6:Hide()
        player5HotstreakImage7:Hide()
        player5HotstreakImage8:Hide()
        player5HotstreakImage9:Hide()
        player5HotstreakImage10:Hide()
        player5HotstreakImage11:Hide()
        player5HotstreakImage12:Hide()
        player5HotstreakImage13:Hide()
        player5HotstreakImage14:Hide()
        player5HotstreakImage15:Hide()

        wageredString = historyFrame.player5totalWageredAmount:GetText()
        wonString = historyFrame.player5totalWonAmount:GetText()
        lostString = historyFrame.player5totalLostAmount:GetText()
        profitString = historyFrame.player5ProfitAmount:GetText()
        bankrollString = bankrollFrame.player5TotalBankrollTableDisplay:GetText()

        wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
        wonAmount = tonumber(string.match(wonString, "(%d+)"))
        lostAmount = tonumber(string.match(lostString, "(%d+)"))
        profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

        -- Store banking information for the leaving player
        if wageredAmount then
            playerBankingInfo[player5Name] = {
                totalWagered = wageredAmount,
                totalWon = wonAmount,
                totalLost = lostAmount,
                totalProfit = profitAmount,
                bankrollTable = bankrollAmount,
                bankrollCashDesk = bankrollAmount
            }
        end

        historyFrame.player5totalWageredAmount:SetText("0 G")
        historyFrame.player5totalWonAmount:SetText("0 G")
        historyFrame.player5totalLostAmount:SetText("0 G")
        historyFrame.player5ProfitAmount:SetText("0 G")
        historyFrame.player5ProfitAmount:SetTextColor(1, 1, 1)

        player5totalBetAmount = 0
        player5totalWin = 0
        player5totalLoss = 0
        player5totalProfit = 0
        player5TotalBankrollAmount = 0

        -- Reset banking information for the leaving player
        unitName5 = nil
        player5Name = nil

    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+left%s+the%s+table%.?") then
        playerLeaving = string.match(message, "{circle}%s+(%S+)%s+has%s+left%s+the%s+table%.?")
        if playerLeaving == unitName1 then
            playerFrame.player1Name:SetText("Seat Empty")
            if playerFrame.player1HitButton:IsShown() or playerFrame.player2HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player4HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
                playerFrame.takeSeat1Button:Disable()
            else
                playerFrame.takeSeat1Button:Enable()
            end
        elseif playerLeaving == unitName2 then
            playerFrame.player2Name:SetText("Seat Empty")
            if playerFrame.player1HitButton:IsShown() or playerFrame.player2HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player4HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
                playerFrame.takeSeat2Button:Disable()
            else
                playerFrame.takeSeat2Button:Enable()
            end
        elseif playerLeaving == unitName3 then
            playerFrame.player3Name:SetText("Seat Empty")
            if playerFrame.player1HitButton:IsShown() or playerFrame.player2HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player4HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
                playerFrame.takeSeat3Button:Disable()
            else
                playerFrame.takeSeat3Button:Enable()
            end
        elseif playerLeaving == unitName4 then
            playerFrame.player4Name:SetText("Seat Empty")
            if playerFrame.player1HitButton:IsShown() or playerFrame.player2HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player4HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
                playerFrame.takeSeat4Button:Disable()
            else
                playerFrame.takeSeat4Button:Enable()
            end
        elseif playerLeaving == unitName5 then
            playerFrame.player5Name:SetText("Seat Empty")
            if playerFrame.player1HitButton:IsShown() or playerFrame.player2HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player4HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
                playerFrame.takeSeat5Button:Disable()
            else
                playerFrame.takeSeat5Button:Enable()
            end
        end
    --
    elseif string.find(message, "%[P1%] PIacing") and string.find(message, "main") then
        player1PlaceCoinsMainBet()
        player1Active = true
        player1MainBet = string.match(message, "(%d+)G")
        if player1MainBet then
            player1PlaceTextMainBet(message)
        else
        end
        if playerName == unitName1 then
            playerFrame.player1DealNowButton:Enable()
        end
    elseif string.find(message, "%[P1%] PIacing") and string.find(message, "Perfect") then
        player1PlaceCoinsPPBet()
        player1PPBet = string.match(message, "(%d+)G")
        if player1PPBet then
            player1PlaceTextPPBet(message)
        else
        end
        if playerName == unitName1 then
            playerFrame.player1DealNowButton:Enable()
        end
    elseif string.find(message, "%[P1%] PIacing") and string.find(message, "21") then
        player1PlaceCoins213Bet()
        player1213Bet = string.match(message, "(%d+)G")
        if player1213Bet then
            player1PlaceText213Bet(message)
        else
        end
        if playerName == unitName1 then
            playerFrame.player1DealNowButton:Enable()
        end
    elseif string.find(message, "%[P1%] Hit") then
        timerReset()
    elseif string.find(message, "%[P1%] %(H1%) Hit") then
        timerReset()
    elseif string.find(message, "%[P1%] %(H2%) Hit") then
        timerReset()
    elseif string.find(message, "%[P1%] Stand") then
        timerReset()

        -- Players: 1
        if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            if player2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            if player3BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            if player4BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            if player5BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player4BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 29
            end
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 29
            end
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 29
            end
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 29
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player4BeforeStandValue == "Blackjack" then
                        if player5BeforeStandValue == "Blackjack" then
                            turn = 111
                        else
                            turn = 91
                        end
                    else
                        turn = 71
                    end
                else
                    turn = 51
                end
            else
                turn = 31
            end
        end

        if player1AfterStandValue then
            playerFrame.player1CardTotalText:SetText(player1AfterStandValue)
        end
        
    elseif string.find(message, "%[P1%] %(H1%) Stand") then
        timerReset()

        -- Players: 1
        if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                turn = 23
            else
                turn = 16
            end
        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            if player1SplitHand2BeforeStandValue == "Blackjack" then 
                if player2BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            else
                turn = 18
            end
        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            if player1SplitHand2BeforeStandValue == "Blackjack" then 
                if player3BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            else
                turn = 18
            end
        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            if player1SplitHand2BeforeStandValue == "Blackjack" then 
                if player4BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            else
                turn = 18
            end
        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            if player1SplitHand2BeforeStandValue == "Blackjack" then 
                if player5BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            else
                turn = 18
            end

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                if player2BeforeStandValue == "Blackjack" then 
                    if player3BeforeStandValue == "Blackjack" then
                        turn = 67
                    else
                        turn = 47
                    end
                else
                    turn = 27
                end
            else
                turn = 20
            end
            -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                if player2BeforeStandValue == "Blackjack" then 
                    if player4BeforeStandValue == "Blackjack" then
                        turn = 67
                    else
                        turn = 47
                    end
                else
                    turn = 27
                end
            else
                turn = 20
            end
            -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                if player2BeforeStandValue == "Blackjack" then 
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 67
                    else
                        turn = 47
                    end
                else
                    turn = 27
                end
            else
                turn = 20
            end
            -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                if player3BeforeStandValue == "Blackjack" then 
                    if player4BeforeStandValue == "Blackjack" then
                        turn = 67
                    else
                        turn = 47
                    end
                else
                    turn = 27
                end
            else
                turn = 20
            end
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                if player3BeforeStandValue == "Blackjack" then 
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 67
                    else
                        turn = 47
                    end
                else
                    turn = 27
                end
            else
                turn = 20
            end
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                if player4BeforeStandValue == "Blackjack" then 
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 67
                    else
                        turn = 47
                    end
                else
                    turn = 27
                end
            else
                turn = 20
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                if player2BeforeStandValue == "Blackjack" then    
                    if player3BeforeStandValue == "Blackjack" then 
                        if player4BeforeStandValue == "Blackjack" then
                            turn = 89
                        else
                            turn = 69
                        end
                    else
                        turn = 49
                    end
                else
                    turn = 29
                end
            else
                turn = 22
            end
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                if player2BeforeStandValue == "Blackjack" then    
                    if player3BeforeStandValue == "Blackjack" then 
                        if player5BeforeStandValue == "Blackjack" then
                            turn = 89
                        else
                            turn = 69
                        end
                    else
                        turn = 49
                    end
                else
                    turn = 29
                end
            else
                turn = 22
            end
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                if player2BeforeStandValue == "Blackjack" then    
                    if player4BeforeStandValue == "Blackjack" then 
                        if player5BeforeStandValue == "Blackjack" then
                            turn = 89
                        else
                            turn = 69
                        end
                    else
                        turn = 49
                    end
                else
                    turn = 29
                end
            else
                turn = 22
            end
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                if player3BeforeStandValue == "Blackjack" then    
                    if player4BeforeStandValue == "Blackjack" then 
                        if player5BeforeStandValue == "Blackjack" then
                            turn = 89
                        else
                            turn = 69
                        end
                    else
                        turn = 49
                    end
                else
                    turn = 29
                end
            else
                turn = 22
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player1SplitHand2BeforeStandValue == "Blackjack" then    
                if player2BeforeStandValue == "Blackjack" then    
                    if player3BeforeStandValue == "Blackjack" then    
                        if player4BeforeStandValue == "Blackjack" then 
                            if player5BeforeStandValue == "Blackjack" then
                                turn = 111
                            else
                                turn = 91
                            end
                        else
                            turn = 71
                        end
                    else
                        turn = 51
                    end
                else
                    turn = 31
                end
            else
                turn = 24
            end

        end

        if player1SplitHand1AfterStandValue then
            playerFrame.player1SplitHand1CardTotalText:SetText(player1SplitHand1AfterStandValue)
        end

    elseif string.find(message, "%[P1%] %(H2%) Stand") then
        timerReset()

        -- Players: 1
        if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            if player2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            if player3BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            if player4BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            if player5BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player4BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 29
            end
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 29
            end
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 29
            end
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 29
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player4BeforeStandValue == "Blackjack" then
                        if player5BeforeStandValue == "Blackjack" then
                            turn = 111
                        else
                            turn = 91
                        end
                    else
                        turn = 71
                    end
                else
                    turn = 51
                end
            else
                turn = 31
            end
        end

        if player1SplitHand2AfterStandValue then
            playerFrame.player1SplitHand2CardTotalText:SetText(player1SplitHand2AfterStandValue)
        end

    elseif string.find(message, "%[P1%] Double") then
        betDoubleAmount1 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmount1 then
            player1PlaceCoinsDoubleBet()
            player1MainBetAmount:SetText(betDoubleAmount1 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                turn = 22

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                turn = 24
            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                turn = 24
            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                turn = 24
            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                turn = 24

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                turn = 26
            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                turn = 26
            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                turn = 26
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                turn = 26
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                turn = 26
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                turn = 26

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 28
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 28
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 28
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 28

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 30
            end

        end
    elseif string.find(message, "%[P1%] %(H1%) Double") then
        betDoubleAmountSplitH1 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmountSplitH1 then
            player1SplitH1BetAmount:SetText(betDoubleAmountSplitH1 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                turn = 15

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                turn = 17
            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                turn = 17
            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                turn = 17
            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                turn = 17

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                turn = 19
            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                turn = 19
            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                turn = 19
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                turn = 19
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                turn = 19
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                turn = 19

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 21
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 21
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 21
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 21

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 23
            end

        end

        playerFrame.player1SplitHand1Coins:Hide()
        playerFrame.player1SplitHand1DoubleCoins:Show()

    elseif string.find(message, "%[P1%] %(H2%) Double") then
        betDoubleAmountSplitH2 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmountSplitH2 then
            player1SplitH2BetAmount:SetText(betDoubleAmountSplitH2 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()
            
            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                turn = 21

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                turn = 23
            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                turn = 23
            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                turn = 23
            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                turn = 23

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                turn = 25
            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                turn = 25
            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                turn = 25
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                turn = 25
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                turn = 25
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                turn = 25

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 27
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 27
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 27
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 27

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 29
            end

        end

        playerFrame.player1SplitHand2Coins:Hide()
        playerFrame.player1SplitHand2DoubleCoins:Show()

    elseif string.find(message, "%[P1%] Split") then
        player1HandleSplit(message)
    --
    elseif string.find(message, "%[P2%] PIacing") and string.find(message, "main") then
        player2PlaceCoinsMainBet() 
        player2Active = true
        player2MainBet = string.match(message, "(%d+)G")
        if player2MainBet then
            player2PlaceTextMainBet(message)
        else
        end
        if playerName == unitName2 then
            playerFrame.player2DealNowButton:Enable()
        end
    elseif string.find(message, "%[P2%] PIacing") and string.find(message, "Perfect") then
        player2PlaceCoinsPPBet()
        player2PPBet = string.match(message, "(%d+)G")
        if player2PPBet then
            player2PlaceTextPPBet(message)
        else
        end
        if playerName == unitName2 then
            playerFrame.player2DealNowButton:Enable()
        end
    elseif string.find(message, "%[P2%] PIacing") and string.find(message, "21") then
        player2PlaceCoins213Bet()
        player2213Bet = string.match(message, "(%d+)G")
        if player2213Bet then
            player2PlaceText213Bet(message)
        else
        end
        if playerName == unitName2 then
            playerFrame.player2DealNowButton:Enable()
        end
    elseif string.find(message, "%[P2%] Hit") then
        timerReset()
    elseif string.find(message, "%[P2%] %(H1%) Hit") then
        timerReset()
    elseif string.find(message, "%[P2%] %(H2%) Hit") then
        timerReset()
    elseif string.find(message, "%[P2%] Stand") then
        timerReset()

        -- Players: 2
        if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            turn = 45
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            if player3BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            if player4BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            if player5BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
            
        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 49
            end
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 49
            end
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 49
            end
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 29
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 111
                    else
                        turn = 91
                    end
                else
                    turn = 71
                end
            else
                turn = 51
            end

        end

        if player2AfterStandValue then
            playerFrame.player2CardTotalText:SetText(player2AfterStandValue)
        end

    elseif string.find(message, "%[P2%] %(H1%) Stand") then
        timerReset()
            
        -- Players: 2
        if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                turn = 23
            else
                turn = 16
            end

        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 38
            end
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            else
                turn = 18
            end
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            else
                turn = 18
            end
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            else
                turn = 18
            end
                
        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 40
            end
        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 40
            end
        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 40
            end
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player4BeforeStandValue == "Blackjack" then
                        turn = 67
                    else
                        turn = 47
                    end
                else
                    turn = 27
                end
            else
                turn = 20
            end
            -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 67
                    else
                        turn = 47
                    end
                else
                    turn = 27
                end
            else
                turn = 20
            end
            -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 67
                    else
                        turn = 47
                    end
                else
                    turn = 27
                end
            else
                turn = 20
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player4BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 42
            end
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 42
            end
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 42
            end
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player4BeforeStandValue == "Blackjack" then
                        if player5BeforeStandValue == "Blackjack" then
                            turn = 89
                        else
                            turn = 69
                        end
                    else
                        turn = 49
                    end
                else
                    turn = 29
                end
            else
                turn = 22
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player2SplitHand2BeforeStandValue == "Blackjack" then
                if player3BeforeStandValue == "Blackjack" then
                    if player4BeforeStandValue == "Blackjack" then
                        if player5BeforeStandValue == "Blackjack" then
                            turn = 111
                        else
                            turn = 91
                        end
                    else
                        turn = 71
                    end
                else
                    turn = 51
                end
            else
                turn = 44
            end

        end

        if player2SplitHand1AfterStandValue then
            playerFrame.player2SplitHand1CardTotalText:SetText(player2SplitHand1AfterStandValue)
        end

    elseif string.find(message, "%[P2%] %(H2%) Stand") then
        timerReset()

        -- Players: 2
        if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 2
        elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
            turn = 45
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            if player3BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            if player4BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            if player5BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
            
        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 49
            end
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 49
            end
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 49
            end
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 29
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player3BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 111
                    else
                        turn = 91
                    end
                else
                    turn = 71
                end
            else
                turn = 51
            end

        end

        if player2SplitHand2AfterStandValue then
            playerFrame.player2SplitHand2CardTotalText:SetText(player2SplitHand2AfterStandValue)
        end

    elseif string.find(message, "%[P2%] Double") then
        betDoubleAmount2 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmount2 then
            player2PlaceCoinsDoubleBet()
            player2MainBetAmount:SetText(betDoubleAmount2 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                turn = 22

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                turn = 44
            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                turn = 24
            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                turn = 24
            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                turn = 24
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                turn = 46
            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                turn = 46
            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                turn = 46
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 26
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 26
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 26

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 48
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 48
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 48
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 28

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 50

            end
        end
    elseif string.find(message, "%[P2%] %(H1%) Double") then
        betDoubleAmountSplitH1 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmountSplitH1 then
            player2SplitH1BetAmount:SetText(betDoubleAmountSplitH1 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                turn = 15

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                turn = 37
            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                turn = 17
            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                turn = 17
            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                turn = 17
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                turn = 39
            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                turn = 39
            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                turn = 39
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 19
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 19
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 19

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 41
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 41
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 41
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 21

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 43

            end

        end

        playerFrame.player2SplitHand1Coins:Hide()
        playerFrame.player2SplitHand1DoubleCoins:Show()

    elseif string.find(message, "%[P2%] %(H2%) Double") then
        betDoubleAmountSplitH2 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmountSplitH2 then
            player2SplitH2BetAmount:SetText(betDoubleAmountSplitH2 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()
            
            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                turn = 21

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                turn = 43
            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                turn = 23
            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                turn = 23
            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                turn = 23
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                turn = 45
            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                turn = 45
            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                turn = 45
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 25
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 25
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 25

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 47
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 47
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 47
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 27

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 49

            end

        end

        playerFrame.player2SplitHand2Coins:Hide()
        playerFrame.player2SplitHand2DoubleCoins:Show()

    elseif string.find(message, "%[P2%] Split") then
        player2HandleSplit(message)
    --
    elseif string.find(message, "%[P3%] PIacing") and string.find(message, "main") then
        player3PlaceCoinsMainBet() 
        player3Active = true
        betAmountMain3 = string.match(message, "(%d+)G")
        if betAmountMain3 then
            player3PlaceTextMainBet(message)
        else
        end
        if playerName == unitName3 then
            playerFrame.player3DealNowButton:Enable()
        end
    elseif string.find(message, "%[P3%] PIacing") and string.find(message, "Perfect") then
        player3PlaceCoinsPPBet()
        betAmountPP3 = string.match(message, "(%d+)G")
        if betAmountPP3 then
            player3PlaceTextPPBet(message)
        else
        end
        if playerName == unitName3 then
            playerFrame.player3DealNowButton:Enable()
        end
    elseif string.find(message, "%[P3%] PIacing") and string.find(message, "21") then
        player3PlaceCoins213Bet()
        betAmount2133 = string.match(message, "(%d+)G")
        if betAmount2133 then
            player3PlaceText213Bet(message)
        else
        end
        if playerName == unitName3 then
            playerFrame.player3DealNowButton:Enable()
        end
    elseif string.find(message, "%[P3%] Hit") then
        timerReset()
    elseif string.find(message, "%[P3%] %(H1%) Hit") then
        timerReset()
    elseif string.find(message, "%[P3%] %(H2%) Hit") then
        timerReset()
    elseif string.find(message, "%[P3%] Stand") then
        timerReset()

        -- Players: 3
        if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 45
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            turn = 45
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            if player4BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            if player5BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            turn = 67
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 69
            end
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 69
            end
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 49
            end
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 49
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 111
                else
                    turn = 91
                end
            else
                turn = 71
            end

        end

        if player3AfterStandValue then
            playerFrame.player3CardTotalText:SetText(player3AfterStandValue)
        end

    elseif string.find(message, "%[P3%] %(H1%) Stand") then
        timerReset()

        -- Players: 3
        if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                turn = 23
            else
                turn = 16
            end

        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 38
            end
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 38
            end
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            else
                turn = 18
            end
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            else
                turn = 18
            end

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 60
            end
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 40
            end
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 40
            end
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 40
            end
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 40
            end
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 67
                    else
                        turn = 47
                    end
                else
                    turn = 27
                end
            else
                turn = 20
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 62
            end
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 62
            end
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 42
            end
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 89
                    else
                        turn = 69
                    end
                else
                    turn = 49
                end
            else
                turn = 42
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player3SplitHand2BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    if player5BeforeStandValue == "Blackjack" then
                        turn = 111
                    else
                        turn = 91
                    end
                else
                    turn = 71
                end
            else
                turn = 64
            end
    
        end

        if player3SplitHand1AfterStandValue then
            playerFrame.player3SplitHand1CardTotalText:SetText(player3SplitHand1AfterStandValue)
        end

    elseif string.find(message, "%[P3%] %(H2%) Stand") then
        timerReset()

        -- Players: 3
        if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 23

        -- Players: 1, 3
        elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
            turn = 45
        -- Players: 2, 3
        elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            turn = 45
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            if player4BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            if player5BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end

        -- Players: 1, 2, 3
        elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            turn = 67
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 27
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 69
            end
        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 69
            end
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 49
            end
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 49
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player4BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 111
                else
                    turn = 91
                end
            else
                turn = 71
            end

        end

        if player3SplitHand2AfterStandValue then
            playerFrame.player3SplitHand2CardTotalText:SetText(player3SplitHand2AfterStandValue)
        end

    elseif string.find(message, "%[P3%] Double") then
        betDoubleAmount3 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmount3 then
            player3PlaceCoinsDoubleBet()
            player3MainBetAmount:SetText(betDoubleAmount3 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                turn = 22

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                turn = 44
            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                turn = 44
            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                turn = 24
            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                turn = 24

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                turn = 66
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                turn = 46
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                turn = 46
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 46
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 46
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 26

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 68
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 68
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 48
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 48

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 70

            end
        end

    elseif string.find(message, "%[P3%] %(H1%) Double") then
        betDoubleAmountSplitH1 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmountSplitH1 then
            player3SplitH1BetAmount:SetText(betDoubleAmountSplitH1 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                turn = 15

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                turn = 37
            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                turn = 37
            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                turn = 17
            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                turn = 17

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                turn = 59
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                turn = 39
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                turn = 39
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 39
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 39
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 19

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 61
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 61
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 41
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 41

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 63

            end
        end

        playerFrame.player3SplitHand1Coins:Hide()
        playerFrame.player3SplitHand1DoubleCoins:Show()

    elseif string.find(message, "%[P3%] %(H2%) Double") then
        betDoubleAmountSplitH2 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmountSplitH2 then
            player3SplitH2BetAmount:SetText(betDoubleAmountSplitH2 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                turn = 21

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                turn = 43
            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                turn = 43
            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                turn = 23
            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                turn = 23

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                turn = 65
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                turn = 45
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                turn = 45
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 45
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 45
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 25

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 67
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 67
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 47
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 47

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 69

            end
        end

        playerFrame.player3SplitHand2Coins:Hide()
        playerFrame.player3SplitHand2DoubleCoins:Show()


    elseif string.find(message, "%[P3%] Split") then
        player3HandleSplit(message) 
    --
    elseif string.find(message, "%[P4%] PIacing") and string.find(message, "main") then
        player4PlaceCoinsMainBet() 
        player4Active = true
        betAmountMain4 = string.match(message, "(%d+)G")
        if betAmountMain4 then
            player4PlaceTextMainBet(message)
        else
        end
        if playerName == unitName4 then
            playerFrame.player4DealNowButton:Enable()
        end
    elseif string.find(message, "%[P4%] PIacing") and string.find(message, "Perfect") then
        player4PlaceCoinsPPBet()
        betAmountPP4 = string.match(message, "(%d+)G")
        if betAmountPP4 then
            player4PlaceTextPPBet(message)
        else
        end
        if playerName == unitName4 then
            playerFrame.player4DealNowButton:Enable()
        end
    elseif string.find(message, "%[P4%] PIacing") and string.find(message, "21") then
        player4PlaceCoins213Bet()
        betAmount2134 = string.match(message, "(%d+)G")
        if betAmount2134 then
            player4PlaceText213Bet(message)
        else
        end
        if playerName == unitName4 then
            playerFrame.player4DealNowButton:Enable()
        end
    elseif string.find(message, "%[P4%] Hit") then
        timerReset()
    elseif string.find(message, "%[P4%] %(H1%) Hit") then
        timerReset()
    elseif string.find(message, "%[P4%] %(H2%) Hit") then
        timerReset()
    elseif string.find(message, "%[P4%] Stand") then
        timerReset()

        -- Players: 4
        if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 23

        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 45
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            turn = 45
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            turn = 45
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            if player5BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end

        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            turn = 67
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            turn = 67
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 67
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 89
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 69
            end
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 69
            end
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 69
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 111
            else
                turn = 91
            end
        end
        
        if player4AfterStandValue then
            playerFrame.player4CardTotalText:SetText(player4AfterStandValue)
        end

    elseif string.find(message, "%[P4%] %(H1%) Stand") then
        timerReset()

        -- Players: 4
        if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                turn = 23
            else
                turn = 16
            end

        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 38
            end
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 38
            end
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 38
            end
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 38
                end
            else
                turn = 18
            end

        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 60
            end
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 60
            end
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 40
            end
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 60
            end
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 40
            end
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            else
                turn = 40
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 82
            end
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 62
            end
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 62
            end
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            else
                turn = 62
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player4SplitHand2BeforeStandValue == "Blackjack" then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 111
                else
                    turn = 91
                end
            else
                turn = 84
            end    
            
        end

        if player4SplitHand1AfterStandValue then
            playerFrame.player4SplitHand1CardTotalText:SetText(player4SplitHand1AfterStandValue)
        end

    elseif string.find(message, "%[P4%] %(H2%) Stand") then
        timerReset()

        -- Players: 4
        if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 23

        -- Players: 1, 4
        elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
            turn = 45
        -- Players: 2, 4
        elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            turn = 45
        -- Players: 3, 4
        elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            turn = 45
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            if player5BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 25
            end

        -- Players: 1, 2, 4
        elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            turn = 67
        -- Players: 1, 3, 4
        elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            turn = 67
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 2, 3, 4
        elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 67
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 47
            end

        -- Players: 1, 2, 3, 4
        elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            turn = 89
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 69
            end
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 69
            end
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 69
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player5BeforeStandValue == "Blackjack" then
                turn = 111
            else
                turn = 91
            end
        end
        
        if player4SplitHand2AfterStandValue then
            playerFrame.player4SplitHand2CardTotalText:SetText(player4SplitHand2AfterStandValue)
        end

    elseif string.find(message, "%[P4%] Double") then
        betDoubleAmount4 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmount4 then
            player4PlaceCoinsDoubleBet()
            player4MainBetAmount:SetText(betDoubleAmount4 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                turn = 22

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                turn = 44
            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                turn = 44
            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                turn = 44
            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                turn = 24

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                turn = 66
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                turn = 66
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                turn = 46
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 66
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 46
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 46

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 88
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 68
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 68
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 68

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 90
            end

        end

    elseif string.find(message, "%[P4%] %(H1%) Double") then
        betDoubleAmountSplitH1 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmountSplitH1 then
            player4SplitH1BetAmount:SetText(betDoubleAmountSplitH1 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                turn = 15

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                turn = 37
            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                turn = 37
            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                turn = 37
            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                turn = 17

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                turn = 59
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                turn = 59
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                turn = 39
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 59
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 39
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 39

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 81
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 61
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 61
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 61

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 83
            end
            
        end

        playerFrame.player4SplitHand1Coins:Hide()
        playerFrame.player4SplitHand1DoubleCoins:Show()

    elseif string.find(message, "%[P4%] %(H2%) Double") then
        betDoubleAmountSplitH2 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmountSplitH2 then
            player4SplitH2BetAmount:SetText(betDoubleAmountSplitH2 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                turn = 21

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                turn = 43
            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                turn = 43
            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                turn = 43
            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                turn = 23

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                turn = 65
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                turn = 65
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                turn = 45
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 65
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 45
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 45

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 87
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 67
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 67
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 67

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 89
            end

        end

        playerFrame.player4SplitHand2Coins:Hide()
        playerFrame.player4SplitHand2DoubleCoins:Show()

    elseif string.find(message, "%[P4%] Split") then 
        player4HandleSplit(message)
    --
    elseif string.find(message, "%[P5%] PIacing") and string.find(message, "main") then
        player5PlaceCoinsMainBet() 
        player5Active = true
        betAmountMain5 = string.match(message, "(%d+)G")
        if betAmountMain5 then
            player5PlaceTextMainBet(message)
        else
        end
        if playerName == unitName5 then
            playerFrame.player5DealNowButton:Enable()
        end
    elseif string.find(message, "%[P5%] PIacing") and string.find(message, "Perfect") then
        player5PlaceCoinsPPBet()
        betAmountPP5 = string.match(message, "(%d+)G")
        if betAmountPP5 then
            player5PlaceTextPPBet(message)
        else
        end
        if playerName == unitName5 then
            playerFrame.player5DealNowButton:Enable()
        end
    elseif string.find(message, "%[P5%] PIacing") and string.find(message, "21") then
        player5PlaceCoins213Bet()
        betAmount2135 = string.match(message, "(%d+)G")
        if betAmount2135 then
            player5PlaceText213Bet(message)
        else
        end
        if playerName == unitName5 then
            playerFrame.player5DealNowButton:Enable()
        end
    elseif string.find(message, "%[P5%] Hit") then
        timerReset()
    elseif string.find(message, "%[P5%] %(H1%) Hit") then
        timerReset()
    elseif string.find(message, "%[P5%] %(H2%) Hit") then
        timerReset()
    elseif string.find(message, "%[P5%] Stand") then
        timerReset()

        -- Players: 5
        if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 23

        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 45
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            turn = 45
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            turn = 45
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            turn = 45

        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            turn = 67
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            turn = 67
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
            turn = 67
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 67
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 67
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 67

        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 89
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 89
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 89
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 89

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 111
        end

        if player5AfterStandValue then
            playerFrame.player5CardTotalText:SetText(player5AfterStandValue)
        end

    elseif string.find(message, "%[P5%] %(H1%) Stand") then
        timerReset()

        -- Players: 5
        if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 23
            else
                turn = 16
            end

        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 18
            end
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 18
            end
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 18
            end
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 45
            else
                turn = 18
            end

        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 60
            end
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 60
            end
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 60
            end
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 60
            end
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 60
            end
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 67
            else
                turn = 60
            end

        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 82
            end
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 82
            end
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 82
            end
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 89
            else
                turn = 82
            end

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            if player5SplitHand2BeforeStandValue == "Blackjack" then
                turn = 111
            else
                turn = 104
            end

        end
        
        if player5SplitHand1AfterStandValue then
            playerFrame.player5SplitHand1CardTotalText:SetText(player5SplitHand1AfterStandValue)
        end

    elseif string.find(message, "%[P5%] %(H2%) Stand") then
        timerReset()

        -- Players: 5
        if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 23

        -- Players: 1, 5
        elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            turn = 45
        -- Players: 2, 5
        elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            turn = 45
        -- Players: 3, 5
        elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            turn = 45
        -- Players: 4, 5
        elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            turn = 45

        -- Players: 1, 2, 5
        elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            turn = 67
        -- Players: 1, 3, 5
        elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            turn = 67
        -- Players: 1, 4, 5
        elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
            turn = 67
        -- Players: 2, 3, 5
        elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 67
        -- Players: 2, 4, 5
        elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 67
        -- Players: 3, 4, 5
        elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 67

        -- Players: 1, 2, 3, 5
        elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            turn = 89
        -- Players: 1, 2, 4, 5
        elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            turn = 89
        -- Players: 1, 3, 4, 5
        elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            turn = 89
        -- Players: 2, 3, 4, 5
        elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 89

        -- Players: 1, 2, 3, 4, 5
        elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            turn = 111
        end

        if player5SplitHand2AfterStandValue then
            playerFrame.player5SplitHand2CardTotalText:SetText(player5SplitHand2AfterStandValue)
        end

    elseif string.find(message, "%[P5%] Double") then
        betDoubleAmount5 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmount5 then
            player5PlaceCoinsDoubleBet()
            player5MainBetAmount:SetText(betDoubleAmount5 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                turn = 22

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                turn = 44
            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                turn = 44
            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                turn = 44
            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                turn = 44

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                turn = 66
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                turn = 66
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                turn = 66
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 66
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 66
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 66

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 88
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 88
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 88
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 88

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 110
            end
        end

    elseif string.find(message, "%[P5%] %(H1%) Double") then
        betDoubleAmountSplitH1 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmountSplitH1 then
            player5SplitH1BetAmount:SetText(betDoubleAmountSplitH1 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                turn = 15

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                turn = 37
            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                turn = 37
            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                turn = 37
            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                turn = 37

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                turn = 59
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                turn = 59
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                turn = 59
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 59
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 59
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 59

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 81
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 81
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 81
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 81

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 103
            end
        end

        playerFrame.player5SplitHand1Coins:Hide()
        playerFrame.player5SplitHand1DoubleCoins:Show()

    elseif string.find(message, "%[P5%] %(H2%) Double") then
        betDoubleAmountSplitH2 = string.match(message, "Double my bet to (%d+)G")
        if betDoubleAmountSplitH2 then
            player5SplitH2BetAmount:SetText(betDoubleAmountSplitH2 .. " G")
            PlaySoundFile(soundFilePaths[33])
            timerReset()

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                turn = 21

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                turn = 43
            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                turn = 43
            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                turn = 43
            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                turn = 43

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                turn = 65
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                turn = 65
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                turn = 65
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 65
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 65
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 65

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 87
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 87
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 87
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 87

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 109
            end
        end

        playerFrame.player5SplitHand2Coins:Hide()
        playerFrame.player5SplitHand2DoubleCoins:Show()

    elseif string.find(message, "%[P5%] Split") then
        player5HandleSplit(message)
    else     
    end

    AddMessageToScrollFrame(message, sender)
end)

-- Chat event to listen for raid leader chat messages
eventFrame = CreateFrame("Frame")
eventFrame:RegisterEvent("CHAT_MSG_RAID_LEADER")
eventFrame:SetScript("OnEvent", function(self, event, message, sender)

    HandleChatMessage(message)
    
    if message == "I have opened the table." then
        local characterName = string.match(sender, "([^%-]+)")
        launchFrame2.dealerStatus:SetText("Dealer: " .. characterName)
        launchFrame3.dealerStatus:SetText("Dealer: " .. characterName)
        currentDealer = characterName
        launchFrame2.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\newUI4.tga")
        launchFrame2.join1Text:SetText(characterName .. "\n<Blackjack Dealer>")
        launchFrame3.join1Text:SetText(characterName .. "\n<Blackjack Dealer>")
        currentDealer = characterName
        EnableJoinButton()
    elseif message == "Version" then
        SendChatMessage("{star} I am running version " .. version .. " {star}", "RAID")
    elseif string.find(message, "has selected") and string.find(message, "DEALER") then
        local characterName = string.match(sender, "([^%-]+)")
        launchFrame2.dealerStatus:SetText("Dealer: " .. characterName)
        launchFrame3.dealerStatus:SetText("Dealer: " .. characterName)
        currentDealer = characterName
        launchFrame2.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\newUI4.tga")
        launchFrame2.join1Text:SetText(characterName .. "\n<Blackjack Dealer>")
        launchFrame3.join1Text:SetText(characterName .. "\n<Blackjack Dealer>")
    elseif string.find(message, "Table ID") then
        pattern = "Table ID: (%d-)%.(%d-)%.(%d-)%.(%d-)%.(%d-)%.(%d-)%.(%d-)%.(%d-)%.(%d-)%.(%d-)%.(%d-)%.(%d-)%.(.-)$"
        variables = {}
    
        for match1, match2, match3, match4, match5, match6, match7, match8, match9, match10, match11, match12, match13 in message:gmatch(pattern) do
            table.insert(variables, match1)
            table.insert(variables, match2)
            table.insert(variables, match3)
            table.insert(variables, match4)
            table.insert(variables, match5)
            table.insert(variables, match6)
            table.insert(variables, match7)
            table.insert(variables, match8)
            table.insert(variables, match9)
            table.insert(variables, match10)
            table.insert(variables, match11)
            table.insert(variables, match12)
            table.insert(variables, match13)
        end
    
        var1 = variables[1] or "N/A"
        var2 = variables[2] or "N/A"
        var3 = variables[3] or "N/A"
        var4 = variables[4] or "N/A"
        var5 = variables[5] or "N/A"
        var6 = variables[6] or "N/A"
        var7 = variables[7] or "N/A"
        var8 = variables[8] or "N/A"
        var9 = variables[9] or "N/A"
        var10 = variables[10] or "N/A"
        var11 = variables[11] or "N/A"
        var12 = variables[12] or "N/A"
        var13 = variables[13] or "N/A"
        
        if var1 == "1" then
            numberOfDecksInShoeText:SetText("1     (52 cards total)")
        elseif var1 == "2" then
            numberOfDecksInShoeText:SetText("2     (104 cards total)")
        elseif var1 == "3" then
            numberOfDecksInShoeText:SetText("3     (156 cards total)")
        elseif var1 == "4" then
            numberOfDecksInShoeText:SetText("4     (208 cards total)")
        elseif var1 == "5" then
            numberOfDecksInShoeText:SetText("5     (260 cards total)")
        elseif var1 == "6" then
            numberOfDecksInShoeText:SetText("6     (312 cards total)")
        elseif var1 == "7" then
            numberOfDecksInShoeText:SetText("7     (364 cards total)")
        elseif var1 == "8" then
            numberOfDecksInShoeText:SetText("8     (416 cards total)")
        end

        minBetMain = tonumber(var2) or 0
        maxBetMain = tonumber(var4) or 0
        minBetPP = tonumber(var3) or 0
        minBet213 = tonumber(var3) or 0
        maxBetPP = tonumber(var5) or 0
        maxBet213 = tonumber(var5) or 0

        tableLimitsMainText:SetText(minBetMain .. "G  -  " .. maxBetMain .."G")
        tableLimitsSideText:SetText(minBetPP .. "G  -  " .. maxBetPP .."G")

        mixedPairPayoutValue = tonumber(var6) or 0
        colouredPairPayoutValue = tonumber(var7) or 0
        perfectPairPayoutValue = tonumber(var8) or 0
        flushPayoutValue = tonumber(var9) or 0
        straightPayoutValue = tonumber(var10) or 0
        threeOfAKindPayoutValue = tonumber(var11) or 0
        straightFlushPayoutValue = tonumber(var12) or 0
        suitedThreeOfAKindPayoutValue = tonumber(var13) or 0

        payoutsFrame.mixedPairPayout:SetText(mixedPairPayoutValue .. ":1")
        payoutsFrame.colouredPairPayout:SetText(colouredPairPayoutValue .. ":1")
        payoutsFrame.perfectPairPayout:SetText(perfectPairPayoutValue .. ":1")
        payoutsFrame.flushPayout:SetText(flushPayoutValue .. ":1")
        payoutsFrame.straightPayout:SetText(straightPayoutValue .. ":1")
        payoutsFrame.threeOfAKindPayout:SetText(threeOfAKindPayoutValue .. ":1")
        payoutsFrame.straightFlushPayout:SetText(straightFlushPayoutValue .. ":1")
        payoutsFrame.suitedThreeOfAKindPayout:SetText(suitedThreeOfAKindPayoutValue .. ":1")

    elseif string.find(message, "has locked the table") then
        tableLocked = true
        player1ConfirmMainBetButton:Disable()
        player1ConfirmPPBetButton:Disable()
        player1Confirm213BetButton:Disable()
        player1PreloadBetButton:Disable()
        player2ConfirmMainBetButton:Disable()
        player2ConfirmPPBetButton:Disable()
        player2Confirm213BetButton:Disable()
        player2PreloadBetButton:Disable()
        player3ConfirmMainBetButton:Disable()
        player3ConfirmPPBetButton:Disable()
        player3Confirm213BetButton:Disable()
        player3PreloadBetButton:Disable()
        player4ConfirmMainBetButton:Disable()
        player4ConfirmPPBetButton:Disable()
        player4Confirm213BetButton:Disable()
        player4PreloadBetButton:Disable()
        player5ConfirmMainBetButton:Disable()
        player5ConfirmPPBetButton:Disable()
        player5Confirm213BetButton:Disable()
        player5PreloadBetButton:Disable()
    elseif string.find(message, "has unlocked the table") then
        tableLocked = false
        player1ConfirmMainBetButton:Enable()
        player1ConfirmPPBetButton:Enable()
        player1Confirm213BetButton:Enable()
        player1PreloadBetButton:Enable()
        player2ConfirmMainBetButton:Enable()
        player2ConfirmPPBetButton:Enable()
        player2Confirm213BetButton:Enable()
        player2PreloadBetButton:Enable()
        player3ConfirmMainBetButton:Enable()
        player3ConfirmPPBetButton:Enable()
        player3Confirm213BetButton:Enable()
        player3PreloadBetButton:Enable()
        player4ConfirmMainBetButton:Enable()
        player4ConfirmPPBetButton:Enable()
        player4Confirm213BetButton:Enable()
        player4PreloadBetButton:Enable()
        player5ConfirmMainBetButton:Enable()
        player5ConfirmPPBetButton:Enable()
        player5Confirm213BetButton:Enable()
        player5PreloadBetButton:Enable()
    elseif string.find(message, "{cross}%s*Seat%s*1:%s*(%S+)%s*") then
        seat1Player = string.match(message, "{cross}%s*Seat%s*1:%s*(%S+)%s*")
        if seat1Player then
            playerFrame.player1Name:SetText(seat1Player)
            unitName1 = seat1Player
            playerFrame.takeSeat1Button:Disable()
        end
    elseif string.find(message, "{triangle}%s*Seat%s*1:%s*Available%s*") then
        playerFrame.player1Name:SetText("Seat Empty")
        unitName1 = nil
        playerFrame.takeSeat1Button:Enable()
    elseif string.find(message, "{cross}%s*Seat%s*2:%s*(%S+)%s*") then
        seat2Player = string.match(message, "{cross}%s*Seat%s*2:%s*(%S+)%s*")
        if seat2Player then
            playerFrame.player2Name:SetText(seat2Player)
            unitName2 = seat2Player
            playerFrame.takeSeat2Button:Disable()
        end
    elseif string.find(message, "{triangle}%s*Seat%s*2:%s*Available%s*") then
        playerFrame.player2Name:SetText("Seat Empty")
        unitName2 = nil
        playerFrame.takeSeat2Button:Enable()
    elseif string.find(message, "{cross}%s*Seat%s*3:%s*(%S+)%s*") then
        seat3Player = string.match(message, "{cross}%s*Seat%s*3:%s*(%S+)%s*")
        if seat3Player then
            playerFrame.player3Name:SetText(seat3Player)
            unitName3 = seat3Player
            playerFrame.takeSeat3Button:Disable()
        end
    elseif string.find(message, "{triangle}%s*Seat%s*3:%s*Available%s*") then
        playerFrame.player3Name:SetText("Seat Empty")
        unitName3 = nil
        playerFrame.takeSeat3Button:Enable()
    elseif string.find(message, "{cross}%s*Seat%s*4:%s*(%S+)%s*") then
        seat4Player = string.match(message, "{cross}%s*Seat%s*4:%s*(%S+)%s*")
        if seat4Player then
            playerFrame.player4Name:SetText(seat4Player)
            unitName4 = seat4Player
            playerFrame.takeSeat4Button:Disable()
        end
    elseif string.find(message, "{triangle}%s*Seat%s*4:%s*Available%s*") then
        playerFrame.player4Name:SetText("Seat Empty")
        unitName4 = nil
        playerFrame.takeSeat4Button:Enable()
    elseif string.find(message, "{cross}%s*Seat%s*5:%s*(%S+)%s*") then
        seat5Player = string.match(message, "{cross}%s*Seat%s*5:%s*(%S+)%s*")
        if seat5Player then
            playerFrame.player5Name:SetText(seat5Player)
            unitName5 = seat5Player
            playerFrame.takeSeat5Button:Disable()
        end
    elseif string.find(message, "{triangle}%s*Seat%s*5:%s*Available%s*") then
        playerFrame.player5Name:SetText("Seat Empty")
        unitName5 = nil
        playerFrame.takeSeat5Button:Enable()
    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+been%s+kicked%s+from%s+Seat%s+1%.?") then
        playerGettingKicked = string.match(message, "{circle}%s+(%S+)%s+has%s+been%s+kicked%s+from%s+Seat%s+1%.?")
        playerFrame.player1Name:SetText("Seat Empty")
        if playerFrame.player2HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player4HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
            playerFrame.takeSeat1Button:Disable()
        else
            playerFrame.takeSeat1Button:Enable()
        end

        player1Hotstreak = 0
        player1HotstreakImage1:Hide()
        player1HotstreakImage2:Hide()
        player1HotstreakImage3:Hide()
        player1HotstreakImage4:Hide()
        player1HotstreakImage5:Hide()
        player1HotstreakImage6:Hide()
        player1HotstreakImage7:Hide()
        player1HotstreakImage8:Hide()
        player1HotstreakImage9:Hide()
        player1HotstreakImage10:Hide()
        player1HotstreakImage11:Hide()
        player1HotstreakImage12:Hide()
        player1HotstreakImage13:Hide()
        player1HotstreakImage14:Hide()
        player1HotstreakImage15:Hide()

        player1totalBetAmount = 0
        player1totalWin = 0
        player1totalLoss = 0
        player1totalProfit = 0
        player1TotalBankrollAmount = 0

        -- Reset banking information for the leaving player
        unitName1 = nil
        player1Name = nil

        if playerName == playerGettingKicked then
            wageredString = historyFrame.player1totalWageredAmount:GetText()
            wonString = historyFrame.player1totalWonAmount:GetText()
            lostString = historyFrame.player1totalLostAmount:GetText()
            profitString = historyFrame.player1ProfitAmount:GetText()
            bankrollString = bankrollFrame.player1TotalBankrollTableDisplay:GetText()

            wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
            wonAmount = tonumber(string.match(wonString, "(%d+)"))
            lostAmount = tonumber(string.match(lostString, "(%d+)"))
            profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
            bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

            -- Store banking information for the leaving player
            if wageredAmount then
                playerBankingInfo[playerName] = {
                    totalWagered = wageredAmount,
                    totalWon = wonAmount,
                    totalLost = lostAmount,
                    totalProfit = profitAmount,
                    bankrollTable = bankrollAmount,
                    bankrollCashDesk = bankrollAmount
                }
            else
                print("wageredAmount == nil")
            end

            historyFrame.player1totalWageredAmount:SetText("0 G")
            historyFrame.player1totalWonAmount:SetText("0 G")
            historyFrame.player1totalLostAmount:SetText("0 G")
            historyFrame.player1ProfitAmount:SetText("0 G")
            historyFrame.player1ProfitAmount:SetTextColor(1, 1, 1)

            player1dealtCardsFrame:Hide()
            player1dealtCardsFrameSplitH1:Hide()
            player1dealtCardsFrameSplitH2:Hide()
            player1PreloadBetButton:Hide()
            player1PreloadEditBoxMainBet:Hide()
            player1PreloadEditBoxPPBet:Hide()
            player1PreloadEditBox213Bet:Hide()
            playerFrame.leaveSeat1Button:Hide()
            playerFrame.player1HitButton:Hide()
            playerFrame.player1StandButton:Hide()
            playerFrame.player1DoubleButton:Hide()
            playerFrame.player1SplitButton:Hide()
            playerFrame.player1InsuranceYesButton:Hide()
            playerFrame.player1InsuranceNoButton:Hide()
            playerFrame.player1DealNowButton:Hide()
            player1ConfirmMainBetButton:Hide()
            player1ConfirmPPBetButton:Hide()
            player1Confirm213BetButton:Hide()
            player1MainBetEditBox:Hide()
            player1PPBetEditBox:Hide()
            player1213BetEditBox:Hide()
            playerFrame.player1MainBetTitle:Hide()
            playerFrame.player1PPBetTitle:Hide()
            playerFrame.player1213BetTitle:Hide()
            playerFrame.player1InsuranceTitle:Hide()
            playerFrame.player1InsuranceSubtitle:Hide()
            menuFrame.cardsButton:Disable()
            playerFrame.historyButton:Disable()
            menuFrame.preloadButton:Disable()
            playerFrame.cashDeskButton:Disable()
            playerFrame.takeSeat1Button:Show()
            if playerFrame.player2Name:GetText() == "Seat Empty" then    
                playerFrame.takeSeat2Button:Enable()
            end
            if playerFrame.player3Name:GetText() == "Seat Empty" then  
                playerFrame.takeSeat3Button:Enable()
            end
            if playerFrame.player4Name:GetText() == "Seat Empty" then 
                playerFrame.takeSeat4Button:Enable()
            end
            if playerFrame.player5Name:GetText() == "Seat Empty" then
                playerFrame.takeSeat5Button:Enable()
            end
            cashDeskFrame.player1TotalBankroll:Hide()
            historyFrame:Hide()
            preloadFrame:Hide()
            historyFrame.player1totalWageredAmount:Hide()
            historyFrame.player1totalWonAmount:Hide()
            historyFrame.player1totalLostAmount:Hide()
            historyFrame.player1ProfitAmount:Hide()
            bankrollFrame.player1TotalBankrollTableDisplay:Hide()
            bankrollFrame.BaseTextDisplay:Show()
            seatFrame:Hide()
            seatFrame.seat1:Hide()
        end
    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+been%s+kicked%s+from%s+Seat%s+2%.?") then
        playerGettingKicked = string.match(message, "{circle}%s+(%S+)%s+has%s+been%s+kicked%s+from%s+Seat%s+2%.?")
        playerFrame.player2Name:SetText("Seat Empty")
        if playerFrame.player1HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player4HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
            playerFrame.takeSeat2Button:Disable()
        else
            playerFrame.takeSeat2Button:Enable()
        end

        player2Hotstreak = 0
        player2HotstreakImage1:Hide()
        player2HotstreakImage2:Hide()
        player2HotstreakImage3:Hide()
        player2HotstreakImage4:Hide()
        player2HotstreakImage5:Hide()
        player2HotstreakImage6:Hide()
        player2HotstreakImage7:Hide()
        player2HotstreakImage8:Hide()
        player2HotstreakImage9:Hide()
        player2HotstreakImage10:Hide()
        player2HotstreakImage11:Hide()
        player2HotstreakImage12:Hide()
        player2HotstreakImage13:Hide()
        player2HotstreakImage14:Hide()
        player2HotstreakImage15:Hide()

        player2totalBetAmount = 0
        player2totalWin = 0
        player2totalLoss = 0
        player2totalProfit = 0
        player2TotalBankrollAmount = 0

        -- Reset banking information for the leaving player
        unitName2 = nil
        player2Name = nil

        if playerName == playerGettingKicked then
            wageredString = historyFrame.player2totalWageredAmount:GetText()
            wonString = historyFrame.player2totalWonAmount:GetText()
            lostString = historyFrame.player2totalLostAmount:GetText()
            profitString = historyFrame.player2ProfitAmount:GetText()
            bankrollString = bankrollFrame.player2TotalBankrollTableDisplay:GetText()

            wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
            wonAmount = tonumber(string.match(wonString, "(%d+)"))
            lostAmount = tonumber(string.match(lostString, "(%d+)"))
            profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
            bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

            -- Store banking information for the leaving player
            if wageredAmount then
                playerBankingInfo[playerName] = {
                    totalWagered = wageredAmount,
                    totalWon = wonAmount,
                    totalLost = lostAmount,
                    totalProfit = profitAmount,
                    bankrollTable = bankrollAmount,
                    bankrollCashDesk = bankrollAmount
                }
            else
                print("wageredAmount == nil")
            end

            historyFrame.player2totalWageredAmount:SetText("0 G")
            historyFrame.player2totalWonAmount:SetText("0 G")
            historyFrame.player2totalLostAmount:SetText("0 G")
            historyFrame.player2ProfitAmount:SetText("0 G")
            historyFrame.player2ProfitAmount:SetTextColor(1, 1, 1)

            player2dealtCardsFrame:Hide()
            player2dealtCardsFrameSplitH1:Hide()
            player2dealtCardsFrameSplitH2:Hide()
            player2PreloadBetButton:Hide()
            player2PreloadEditBoxMainBet:Hide()
            player2PreloadEditBoxPPBet:Hide()
            player2PreloadEditBox213Bet:Hide()
            playerFrame.leaveSeat2Button:Hide()
            playerFrame.player2HitButton:Hide()
            playerFrame.player2StandButton:Hide()
            playerFrame.player2DoubleButton:Hide()
            playerFrame.player2SplitButton:Hide()
            playerFrame.player2InsuranceYesButton:Hide()
            playerFrame.player2InsuranceNoButton:Hide()
            playerFrame.player2DealNowButton:Hide()
            player2ConfirmMainBetButton:Hide()
            player2ConfirmPPBetButton:Hide()
            player2Confirm213BetButton:Hide()
            player2MainBetEditBox:Hide()
            player2PPBetEditBox:Hide()
            player2213BetEditBox:Hide()
            playerFrame.player2MainBetTitle:Hide()
            playerFrame.player2PPBetTitle:Hide()
            playerFrame.player2213BetTitle:Hide()
            playerFrame.player2InsuranceTitle:Hide()
            playerFrame.player2InsuranceSubtitle:Hide()
            menuFrame.cardsButton:Disable()
            playerFrame.historyButton:Disable()
            menuFrame.preloadButton:Disable()
            playerFrame.cashDeskButton:Disable()
            playerFrame.takeSeat2Button:Show()
            if playerFrame.player1Name:GetText() == "Seat Empty" then    
                playerFrame.takeSeat1Button:Enable()
            end
            if playerFrame.player3Name:GetText() == "Seat Empty" then  
                playerFrame.takeSeat3Button:Enable()
            end
            if playerFrame.player4Name:GetText() == "Seat Empty" then 
                playerFrame.takeSeat4Button:Enable()
            end
            if playerFrame.player5Name:GetText() == "Seat Empty" then
                playerFrame.takeSeat5Button:Enable()
            end
            cashDeskFrame.player2TotalBankroll:Hide()
            historyFrame:Hide()
            preloadFrame:Hide()
            historyFrame.player2totalWageredAmount:Hide()
            historyFrame.player2totalWonAmount:Hide()
            historyFrame.player2totalLostAmount:Hide()
            historyFrame.player2ProfitAmount:Hide()
            bankrollFrame.player2TotalBankrollTableDisplay:Hide()
            bankrollFrame.BaseTextDisplay:Show()
            seatFrame:Hide()
            seatFrame.seat2:Hide()
        end

    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+been%s+kicked%s+from%s+Seat%s+3%.?") then
        playerGettingKicked = string.match(message, "{circle}%s+(%S+)%s+has%s+been%s+kicked%s+from%s+Seat%s+3%.?")
        playerFrame.player3Name:SetText("Seat Empty")
        if playerFrame.player1HitButton:IsShown() or playerFrame.player2HitButton:IsShown() or playerFrame.player4HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
            playerFrame.takeSeat3Button:Disable()
        else
            playerFrame.takeSeat3Button:Enable()
        end

        player3Hotstreak = 0
        player3HotstreakImage1:Hide()
        player3HotstreakImage2:Hide()
        player3HotstreakImage3:Hide()
        player3HotstreakImage4:Hide()
        player3HotstreakImage5:Hide()
        player3HotstreakImage6:Hide()
        player3HotstreakImage7:Hide()
        player3HotstreakImage8:Hide()
        player3HotstreakImage9:Hide()
        player3HotstreakImage10:Hide()
        player3HotstreakImage11:Hide()
        player3HotstreakImage12:Hide()
        player3HotstreakImage13:Hide()
        player3HotstreakImage14:Hide()
        player3HotstreakImage15:Hide()

        player3totalBetAmount = 0
        player3totalWin = 0
        player3totalLoss = 0
        player3totalProfit = 0
        player3TotalBankrollAmount = 0

        -- Reset banking information for the leaving player
        unitName3 = nil
        player3Name = nil

        if playerName == playerGettingKicked then
            wageredString = historyFrame.player3totalWageredAmount:GetText()
            wonString = historyFrame.player3totalWonAmount:GetText()
            lostString = historyFrame.player3totalLostAmount:GetText()
            profitString = historyFrame.player3ProfitAmount:GetText()
            bankrollString = bankrollFrame.player3TotalBankrollTableDisplay:GetText()

            wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
            wonAmount = tonumber(string.match(wonString, "(%d+)"))
            lostAmount = tonumber(string.match(lostString, "(%d+)"))
            profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
            bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

            -- Store banking information for the leaving player
            if wageredAmount then
                playerBankingInfo[playerName] = {
                    totalWagered = wageredAmount,
                    totalWon = wonAmount,
                    totalLost = lostAmount,
                    totalProfit = profitAmount,
                    bankrollTable = bankrollAmount,
                    bankrollCashDesk = bankrollAmount
                }
            else
                print("wageredAmount == nil")
            end

            historyFrame.player3totalWageredAmount:SetText("0 G")
            historyFrame.player3totalWonAmount:SetText("0 G")
            historyFrame.player3totalLostAmount:SetText("0 G")
            historyFrame.player3ProfitAmount:SetText("0 G")
            historyFrame.player3ProfitAmount:SetTextColor(1, 1, 1)

            player3dealtCardsFrame:Hide()
            player3dealtCardsFrameSplitH1:Hide()
            player3dealtCardsFrameSplitH2:Hide()
            player3PreloadBetButton:Hide()
            player3PreloadEditBoxMainBet:Hide()
            player3PreloadEditBoxPPBet:Hide()
            player3PreloadEditBox213Bet:Hide()
            playerFrame.leaveSeat3Button:Hide()
            playerFrame.player3HitButton:Hide()
            playerFrame.player3StandButton:Hide()
            playerFrame.player3DoubleButton:Hide()
            playerFrame.player3SplitButton:Hide()
            playerFrame.player3InsuranceYesButton:Hide()
            playerFrame.player3InsuranceNoButton:Hide()
            playerFrame.player3DealNowButton:Hide()
            player3ConfirmMainBetButton:Hide()
            player3ConfirmPPBetButton:Hide()
            player3Confirm213BetButton:Hide()
            player3MainBetEditBox:Hide()
            player3PPBetEditBox:Hide()
            player3213BetEditBox:Hide()
            playerFrame.player3MainBetTitle:Hide()
            playerFrame.player3PPBetTitle:Hide()
            playerFrame.player3213BetTitle:Hide()
            playerFrame.player3InsuranceTitle:Hide()
            playerFrame.player3InsuranceSubtitle:Hide()
            menuFrame.cardsButton:Disable()
            playerFrame.historyButton:Disable()
            menuFrame.preloadButton:Disable()
            playerFrame.cashDeskButton:Disable()
            playerFrame.takeSeat3Button:Show()
            if playerFrame.player1Name:GetText() == "Seat Empty" then    
                playerFrame.takeSeat1Button:Enable()
            end
            if playerFrame.player2Name:GetText() == "Seat Empty" then  
                playerFrame.takeSeat2Button:Enable()
            end
            if playerFrame.player4Name:GetText() == "Seat Empty" then 
                playerFrame.takeSeat4Button:Enable()
            end
            if playerFrame.player5Name:GetText() == "Seat Empty" then
                playerFrame.takeSeat5Button:Enable()
            end
            cashDeskFrame.player3TotalBankroll:Hide()
            historyFrame:Hide()
            preloadFrame:Hide()
            historyFrame.player3totalWageredAmount:Hide()
            historyFrame.player3totalWonAmount:Hide()
            historyFrame.player3totalLostAmount:Hide()
            historyFrame.player3ProfitAmount:Hide()
            bankrollFrame.player3TotalBankrollTableDisplay:Hide()
            bankrollFrame.BaseTextDisplay:Show()
            seatFrame:Hide()
            seatFrame.seat3:Hide()
        end

    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+been%s+kicked%s+from%s+Seat%s+4%.?") then
        playerGettingKicked = string.match(message, "{circle}%s+(%S+)%s+has%s+been%s+kicked%s+from%s+Seat%s+4%.?")
        playerFrame.player4Name:SetText("Seat Empty")
        if playerFrame.player1HitButton:IsShown() or playerFrame.player2HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player5HitButton:IsShown() then
            playerFrame.takeSeat4Button:Disable()
        else
            playerFrame.takeSeat4Button:Enable()
        end

        player4Hotstreak = 0
        player4HotstreakImage1:Hide()
        player4HotstreakImage2:Hide()
        player4HotstreakImage3:Hide()
        player4HotstreakImage4:Hide()
        player4HotstreakImage5:Hide()
        player4HotstreakImage6:Hide()
        player4HotstreakImage7:Hide()
        player4HotstreakImage8:Hide()
        player4HotstreakImage9:Hide()
        player4HotstreakImage10:Hide()
        player4HotstreakImage11:Hide()
        player4HotstreakImage12:Hide()
        player4HotstreakImage13:Hide()
        player4HotstreakImage14:Hide()
        player4HotstreakImage15:Hide()

        player4totalBetAmount = 0
        player4totalWin = 0
        player4totalLoss = 0
        player4totalProfit = 0
        player4TotalBankrollAmount = 0

        -- Reset banking information for the leaving player
        unitName4 = nil
        player4Name = nil

        if playerName == playerGettingKicked then
            wageredString = historyFrame.player4totalWageredAmount:GetText()
            wonString = historyFrame.player4totalWonAmount:GetText()
            lostString = historyFrame.player4totalLostAmount:GetText()
            profitString = historyFrame.player4ProfitAmount:GetText()
            bankrollString = bankrollFrame.player4TotalBankrollTableDisplay:GetText()

            wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
            wonAmount = tonumber(string.match(wonString, "(%d+)"))
            lostAmount = tonumber(string.match(lostString, "(%d+)"))
            profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
            bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

            -- Store banking information for the leaving player
            if wageredAmount then
                playerBankingInfo[playerName] = {
                    totalWagered = wageredAmount,
                    totalWon = wonAmount,
                    totalLost = lostAmount,
                    totalProfit = profitAmount,
                    bankrollTable = bankrollAmount,
                    bankrollCashDesk = bankrollAmount
                }
            else
                print("wageredAmount == nil")
            end

            historyFrame.player4totalWageredAmount:SetText("0 G")
            historyFrame.player4totalWonAmount:SetText("0 G")
            historyFrame.player4totalLostAmount:SetText("0 G")
            historyFrame.player4ProfitAmount:SetText("0 G")
            historyFrame.player4ProfitAmount:SetTextColor(1, 1, 1)

            player4dealtCardsFrame:Hide()
            player4dealtCardsFrameSplitH1:Hide()
            player4dealtCardsFrameSplitH2:Hide()
            player4PreloadBetButton:Hide()
            player4PreloadEditBoxMainBet:Hide()
            player4PreloadEditBoxPPBet:Hide()
            player4PreloadEditBox213Bet:Hide()
            playerFrame.leaveSeat4Button:Hide()
            playerFrame.player4HitButton:Hide()
            playerFrame.player4StandButton:Hide()
            playerFrame.player4DoubleButton:Hide()
            playerFrame.player4SplitButton:Hide()
            playerFrame.player4InsuranceYesButton:Hide()
            playerFrame.player4InsuranceNoButton:Hide()
            playerFrame.player4DealNowButton:Hide()
            player4ConfirmMainBetButton:Hide()
            player4ConfirmPPBetButton:Hide()
            player4Confirm213BetButton:Hide()
            player4MainBetEditBox:Hide()
            player4PPBetEditBox:Hide()
            player4213BetEditBox:Hide()
            playerFrame.player4MainBetTitle:Hide()
            playerFrame.player4PPBetTitle:Hide()
            playerFrame.player4213BetTitle:Hide()
            playerFrame.player4InsuranceTitle:Hide()
            playerFrame.player4InsuranceSubtitle:Hide()
            menuFrame.cardsButton:Disable()
            playerFrame.historyButton:Disable()
            menuFrame.preloadButton:Disable()
            playerFrame.cashDeskButton:Disable()
            playerFrame.takeSeat4Button:Show()
            if playerFrame.player1Name:GetText() == "Seat Empty" then    
                playerFrame.takeSeat1Button:Enable()
            end
            if playerFrame.player2Name:GetText() == "Seat Empty" then  
                playerFrame.takeSeat2Button:Enable()
            end
            if playerFrame.player3Name:GetText() == "Seat Empty" then 
                playerFrame.takeSeat3Button:Enable()
            end
            if playerFrame.player5Name:GetText() == "Seat Empty" then
                playerFrame.takeSeat5Button:Enable()
            end
            cashDeskFrame.player4TotalBankroll:Hide()
            historyFrame:Hide()
            preloadFrame:Hide()
            historyFrame.player4totalWageredAmount:Hide()
            historyFrame.player4totalWonAmount:Hide()
            historyFrame.player4totalLostAmount:Hide()
            historyFrame.player4ProfitAmount:Hide()
            bankrollFrame.player4TotalBankrollTableDisplay:Hide()
            bankrollFrame.BaseTextDisplay:Show()
            seatFrame:Hide()
            seatFrame.seat4:Hide()
        end

    elseif string.find(message, "{circle}%s+(%S+)%s+has%s+been%s+kicked%s+from%s+Seat%s+5%.?") then
        playerGettingKicked = string.match(message, "{circle}%s+(%S+)%s+has%s+been%s+kicked%s+from%s+Seat%s+5%.?")
        playerFrame.player5Name:SetText("Seat Empty")
        if playerFrame.player1HitButton:IsShown() or playerFrame.player2HitButton:IsShown() or playerFrame.player3HitButton:IsShown() or playerFrame.player4HitButton:IsShown() then
            playerFrame.takeSeat5Button:Disable()
        else
            playerFrame.takeSeat5Button:Enable()
        end

        player5Hotstreak = 0
        player5HotstreakImage1:Hide()
        player5HotstreakImage2:Hide()
        player5HotstreakImage3:Hide()
        player5HotstreakImage4:Hide()
        player5HotstreakImage5:Hide()
        player5HotstreakImage6:Hide()
        player5HotstreakImage7:Hide()
        player5HotstreakImage8:Hide()
        player5HotstreakImage9:Hide()
        player5HotstreakImage10:Hide()
        player5HotstreakImage11:Hide()
        player5HotstreakImage12:Hide()
        player5HotstreakImage13:Hide()
        player5HotstreakImage14:Hide()
        player5HotstreakImage15:Hide()

        player5totalBetAmount = 0
        player5totalWin = 0
        player5totalLoss = 0
        player5totalProfit = 0
        player5TotalBankrollAmount = 0

        -- Reset banking information for the leaving player
        unitName5 = nil
        player5Name = nil

        if playerName == playerGettingKicked then
            wageredString = historyFrame.player5totalWageredAmount:GetText()
            wonString = historyFrame.player5totalWonAmount:GetText()
            lostString = historyFrame.player5totalLostAmount:GetText()
            profitString = historyFrame.player5ProfitAmount:GetText()
            bankrollString = bankrollFrame.player5TotalBankrollTableDisplay:GetText()

            wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
            wonAmount = tonumber(string.match(wonString, "(%d+)"))
            lostAmount = tonumber(string.match(lostString, "(%d+)"))
            profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
            bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

            -- Store banking information for the leaving player
            if wageredAmount then
                playerBankingInfo[playerName] = {
                    totalWagered = wageredAmount,
                    totalWon = wonAmount,
                    totalLost = lostAmount,
                    totalProfit = profitAmount,
                    bankrollTable = bankrollAmount,
                    bankrollCashDesk = bankrollAmount
                }
            else
                print("wageredAmount == nil")
            end

            historyFrame.player5totalWageredAmount:SetText("0 G")
            historyFrame.player5totalWonAmount:SetText("0 G")
            historyFrame.player5totalLostAmount:SetText("0 G")
            historyFrame.player5ProfitAmount:SetText("0 G")
            historyFrame.player5ProfitAmount:SetTextColor(1, 1, 1)

            player5dealtCardsFrame:Hide()
            player5dealtCardsFrameSplitH1:Hide()
            player5dealtCardsFrameSplitH2:Hide()
            player5PreloadBetButton:Hide()
            player5PreloadEditBoxMainBet:Hide()
            player5PreloadEditBoxPPBet:Hide()
            player5PreloadEditBox213Bet:Hide()
            playerFrame.leaveSeat5Button:Hide()
            playerFrame.player5HitButton:Hide()
            playerFrame.player5StandButton:Hide()
            playerFrame.player5DoubleButton:Hide()
            playerFrame.player5SplitButton:Hide()
            playerFrame.player5InsuranceYesButton:Hide()
            playerFrame.player5InsuranceNoButton:Hide()
            playerFrame.player5DealNowButton:Hide()
            player5ConfirmMainBetButton:Hide()
            player5ConfirmPPBetButton:Hide()
            player5Confirm213BetButton:Hide()
            player5MainBetEditBox:Hide()
            player5PPBetEditBox:Hide()
            player5213BetEditBox:Hide()
            playerFrame.player5MainBetTitle:Hide()
            playerFrame.player5PPBetTitle:Hide()
            playerFrame.player5213BetTitle:Hide()
            playerFrame.player5InsuranceTitle:Hide()
            playerFrame.player5InsuranceSubtitle:Hide()
            menuFrame.cardsButton:Disable()
            playerFrame.historyButton:Disable()
            menuFrame.preloadButton:Disable()
            playerFrame.cashDeskButton:Disable()
            playerFrame.takeSeat5Button:Show()
            if playerFrame.player1Name:GetText() == "Seat Empty" then    
                playerFrame.takeSeat1Button:Enable()
            end
            if playerFrame.player2Name:GetText() == "Seat Empty" then  
                playerFrame.takeSeat2Button:Enable()
            end
            if playerFrame.player3Name:GetText() == "Seat Empty" then 
                playerFrame.takeSeat3Button:Enable()
            end
            if playerFrame.player4Name:GetText() == "Seat Empty" then
                playerFrame.takeSeat4Button:Enable()
            end
            cashDeskFrame.player5TotalBankroll:Hide()
            historyFrame:Hide()
            preloadFrame:Hide()
            historyFrame.player5totalWageredAmount:Hide()
            historyFrame.player5totalWonAmount:Hide()
            historyFrame.player5totalLostAmount:Hide()
            historyFrame.player5ProfitAmount:Hide()
            bankrollFrame.player5TotalBankrollTableDisplay:Hide()
            bankrollFrame.BaseTextDisplay:Show()
            seatFrame:Hide()
            seatFrame.seat5:Hide()
        end

    elseif message == "I have closed the table." then
        PlayerFrameHide()
        resetHistory()
    elseif message == "I have started a new round." then
        betReset()
        RemoveCardTextures()
    elseif message == "{diamond} Insurance is available." then
        insuranceAvailable()
    elseif string.find(message, "{triangle} Split is available") then
        if unitName1 and string.find(message, unitName1) then
            playerFrame.player1SplitButton:Enable()
        elseif unitName2 and string.find(message, unitName2) then
            playerFrame.player2SplitButton:Enable()
        elseif unitName3 and string.find(message, unitName3) then
            playerFrame.player3SplitButton:Enable()
        elseif unitName4 and string.find(message, unitName4) then
            playerFrame.player4SplitButton:Enable()
        elseif unitName5 and string.find(message, unitName5) then
            playerFrame.player5SplitButton:Enable()
        end
    elseif string.find(message, "Main Bet: Min:") then
        usingThisToAvoidUpvalues1 = tonumber(string.match(message, "(%d+)G"))
        minBetMain = usingThisToAvoidUpvalues1
    elseif string.find(message, "Main Bet: Max:") then
        usingThisToAvoidUpvalues2 = tonumber(string.match(message, "(%d+)G"))
        maxBetMain = usingThisToAvoidUpvalues2
    elseif string.find(message, "Side Bets: Min:") then
        usingThisToAvoidUpvalues3 = tonumber(string.match(message, "(%d+)G"))
        minBetPP = usingThisToAvoidUpvalues3
        minBet213 = usingThisToAvoidUpvalues3
    elseif string.find(message, "Side Bets: Max:") then
        usingThisToAvoidUpvalues4 = tonumber(string.match(message, "(%d+)G"))
        maxBetPP = usingThisToAvoidUpvalues4
        maxBet213 = usingThisToAvoidUpvalues4
        tableLimitsMainText:SetText(minBetMain .. "G  -  " .. maxBetMain .."G")
        tableLimitsSideText:SetText(minBetPP .. "G  -  " .. maxBetPP .."G")
    elseif string.find(message, "Switching to a 1%-deck shoe") then
        numberOfDecksInShoeText:SetText("1     (52 cards total)")
    elseif string.find(message, "Switching to a 2%-deck shoe") then
        numberOfDecksInShoeText:SetText("2     (104 cards total)")
    elseif string.find(message, "Switching to a 3%-deck shoe") then
        numberOfDecksInShoeText:SetText("3     (156 cards total)")
    elseif string.find(message, "Switching to a 4%-deck shoe") then
        numberOfDecksInShoeText:SetText("4     (208 cards total)")
    elseif string.find(message, "Switching to a 5%-deck shoe") then
        numberOfDecksInShoeText:SetText("5     (260 cards total)")
    elseif string.find(message, "Switching to a 6%-deck shoe") then
        numberOfDecksInShoeText:SetText("6     (312 cards total)")
    elseif string.find(message, "Switching to a 7%-deck shoe") then
        numberOfDecksInShoeText:SetText("7     (364 cards total)")
    elseif string.find(message, "Switching to a 8%-deck shoe") then
        numberOfDecksInShoeText:SetText("8     (416 cards total)")
    elseif message == "{star} Place your bets! You have 30 seconds." then
        StartCountdownTimerBets()
    elseif string.find(message, "added") then
        if string.find(message, playerName) then
            if playerName == unitName1 then
                PlaySoundFile(soundFilePaths[115])
                additionalBankrollAmountString = string.match(message, "([%d%.]+)G") 
                if additionalBankrollAmountString then
                    additionalBankrollAmount = tonumber(additionalBankrollAmountString)
                    if additionalBankrollAmount then
                        player1TotalBankrollAmount = player1TotalBankrollAmount + additionalBankrollAmount
                        cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
                        bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
                        bankrollString = bankrollFrame.player1TotalBankrollTableDisplay:GetText()
                        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))
                        playerBankingInfo[playerName] = {
                            bankrollTable = bankrollAmount,
                            bankrollCashDesk = bankrollAmount
                        }
                    end
                end
            elseif playerName == unitName2 then
                PlaySoundFile(soundFilePaths[115])
                additionalBankrollAmountString = string.match(message, "([%d%.]+)G") 
                if additionalBankrollAmountString then
                    additionalBankrollAmount = tonumber(additionalBankrollAmountString)
                    if additionalBankrollAmount then
                        player2TotalBankrollAmount = player2TotalBankrollAmount + additionalBankrollAmount
                        cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
                        bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
                        bankrollString = bankrollFrame.player2TotalBankrollTableDisplay:GetText()
                        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))
                        playerBankingInfo[playerName] = {
                            bankrollTable = bankrollAmount,
                            bankrollCashDesk = bankrollAmount
                        }
                    end
                end
            elseif playerName == unitName3 then
                PlaySoundFile(soundFilePaths[115])
                additionalBankrollAmountString = string.match(message, "([%d%.]+)G") 
                if additionalBankrollAmountString then
                    additionalBankrollAmount = tonumber(additionalBankrollAmountString)
                    if additionalBankrollAmount then
                        player3TotalBankrollAmount = player3TotalBankrollAmount + additionalBankrollAmount
                        cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
                        bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
                        bankrollString = bankrollFrame.player3TotalBankrollTableDisplay:GetText()
                        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))
                        playerBankingInfo[playerName] = {
                            bankrollTable = bankrollAmount,
                            bankrollCashDesk = bankrollAmount
                        }
                    end
                end
            elseif playerName == unitName4 then
                PlaySoundFile(soundFilePaths[115])
                additionalBankrollAmountString = string.match(message, "([%d%.]+)G") 
                if additionalBankrollAmountString then
                    additionalBankrollAmount = tonumber(additionalBankrollAmountString)
                    if additionalBankrollAmount then
                        player4TotalBankrollAmount = player4TotalBankrollAmount + additionalBankrollAmount
                        cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
                        bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
                        bankrollString = bankrollFrame.player4TotalBankrollTableDisplay:GetText()
                        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))
                        playerBankingInfo[playerName] = {
                            bankrollTable = bankrollAmount,
                            bankrollCashDesk = bankrollAmount
                        }
                    end
                end
            elseif playerName == unitName5 then
                PlaySoundFile(soundFilePaths[115])
                additionalBankrollAmountString = string.match(message, "([%d%.]+)G") 
                if additionalBankrollAmountString then
                    additionalBankrollAmount = tonumber(additionalBankrollAmountString)
                    if additionalBankrollAmount then
                        player5TotalBankrollAmount = player5TotalBankrollAmount + additionalBankrollAmount
                        cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
                        bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
                        bankrollString = bankrollFrame.player5TotalBankrollTableDisplay:GetText()
                        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))
                        playerBankingInfo[playerName] = {
                            bankrollTable = bankrollAmount,
                            bankrollCashDesk = bankrollAmount
                        }
                    end
                end
            end
        end
    elseif string.find(message, "withdrew") then
        if string.find(message, playerName) then
            if playerName == unitName1 then
                removalBankrollAmountString = string.match(message, "([%d%.]+)G")
                if removalBankrollAmountString then
                    removalBankrollAmount = tonumber(removalBankrollAmountString)
                    if removalBankrollAmount then
                        player1TotalBankrollAmount = player1TotalBankrollAmount - removalBankrollAmount
                        cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
                        bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
                        bankrollString = bankrollFrame.player1TotalBankrollTableDisplay:GetText()
                        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))
                        playerBankingInfo[playerName] = {
                            bankrollTable = bankrollAmount,
                            bankrollCashDesk = bankrollAmount
                        }
                    end
                end
            elseif playerName == unitName2 then
                removalBankrollAmountString = string.match(message, "([%d%.]+)G")
                if removalBankrollAmountString then
                    removalBankrollAmount = tonumber(removalBankrollAmountString)
                    if removalBankrollAmount then
                        player2TotalBankrollAmount = player2TotalBankrollAmount - removalBankrollAmount
                        cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
                        bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
                        bankrollString = bankrollFrame.player2TotalBankrollTableDisplay:GetText()
                        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))
                        playerBankingInfo[playerName] = {
                            bankrollTable = bankrollAmount,
                            bankrollCashDesk = bankrollAmount
                        }
                    end
                end
            elseif playerName == unitName3 then
                removalBankrollAmountString = string.match(message, "([%d%.]+)G")
                if removalBankrollAmountString then
                    removalBankrollAmount = tonumber(removalBankrollAmountString)
                    if removalBankrollAmount then
                        player3TotalBankrollAmount = player3TotalBankrollAmount - removalBankrollAmount
                        cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
                        bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
                        bankrollString = bankrollFrame.player3TotalBankrollTableDisplay:GetText()
                        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))
                        playerBankingInfo[playerName] = {
                            bankrollTable = bankrollAmount,
                            bankrollCashDesk = bankrollAmount
                        }
                    end
                end
            elseif playerName == unitName4 then
                removalBankrollAmountString = string.match(message, "([%d%.]+)G")
                if removalBankrollAmountString then
                    removalBankrollAmount = tonumber(removalBankrollAmountString)
                    if removalBankrollAmount then
                        player4TotalBankrollAmount = player4TotalBankrollAmount - removalBankrollAmount
                        cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
                        bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
                        bankrollString = bankrollFrame.player4TotalBankrollTableDisplay:GetText()
                        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))
                        playerBankingInfo[playerName] = {
                            bankrollTable = bankrollAmount,
                            bankrollCashDesk = bankrollAmount
                        }
                    end
                end
            elseif playerName == unitName5 then
                removalBankrollAmountString = string.match(message, "([%d%.]+)G")
                if removalBankrollAmountString then
                    removalBankrollAmount = tonumber(removalBankrollAmountString)
                    if removalBankrollAmount then
                        player5TotalBankrollAmount = player5TotalBankrollAmount - removalBankrollAmount
                        cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
                        bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
                        bankrollString = bankrollFrame.player5TotalBankrollTableDisplay:GetText()
                        bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))
                        playerBankingInfo[playerName] = {
                            bankrollTable = bankrollAmount,
                            bankrollCashDesk = bankrollAmount
                        }
                    end
                end
            end
        end
    elseif string.find(message, "received") then
        roundStarted()
        gameRunning = true
        PlaySoundFile(soundFilePaths[32])
        if unitName1 and string.find(message, unitName1) then

            player1dealtCardsFrame.notStartedYetText:Hide()

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then

                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 3 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[3]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[3]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 4 or turn == 23 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[4]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 5 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[5]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 6 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[6]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 7 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[7]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 8 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[8]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 9 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[4]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[5]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 or turn == 16 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[6]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[7]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[8]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[9]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[10]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 or turn == 22 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 4]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 5]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 6]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 20 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then

                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 4 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 6 or turn == 25 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 7 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 8 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 9 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 or turn == 18 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 or turn == 24 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 5]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 6]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 20 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 22 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 4 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 6 or turn == 25 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 7 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 8 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 9 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 or turn == 18 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 or turn == 24 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 5]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 6]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 20 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 22 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 4 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 6 or turn == 25 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 7 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 8 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 9 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 or turn == 18 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 or turn == 24 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 5]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 6]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 20 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 22 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 4 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 6 or turn == 25 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 7 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 8 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 9 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 or turn == 18 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 or turn == 24 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 5]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 6]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 20 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 22 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 5 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 8 or turn == 27 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 9 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 or turn == 20 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 or turn == 26 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 6]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 22 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 23 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 24 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 25 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 10]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 5 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 8 or turn == 27 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 9 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 or turn == 20 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 or turn == 26 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 6]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 22 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 23 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 24 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 25 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 10]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 5 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 8 or turn == 27 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 9 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 or turn == 20 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 or turn == 26 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 6]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 22 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 23 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 24 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 25 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 10]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 5 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 8 or turn == 27 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 9 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 or turn == 20 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 or turn == 26 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 6]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 22 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 23 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 24 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 25 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 10]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 5 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 8 or turn == 27 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 9 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 or turn == 20 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 or turn == 26 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 6]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 22 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 23 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 24 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 25 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 10]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 5 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 8 or turn == 27 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 9 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 or turn == 20 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 or turn == 26 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 6]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 22 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 23 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 24 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 25 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 10]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 6 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 or turn == 29 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 or turn == 22 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 20 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 23 or turn == 28 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 24 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 25 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 26 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 10]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 27 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 11]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 6 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 or turn == 29 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 or turn == 22 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 20 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 23 or turn == 28 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 24 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 25 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 26 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 10]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 27 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 11]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 6 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 or turn == 29 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 or turn == 22 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 20 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 23 or turn == 28 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 24 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 25 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 26 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 10]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 27 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 11]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 6 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 10 or turn == 29 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 11 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 or turn == 22 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 20 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 23 or turn == 28 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 7]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 24 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 25 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 26 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 10]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 27 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 11]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                if turn == 1 then -- Player 1: 1st Card
                    player1MainCardName1 = dealtCards[1]
                    player1MainCardFileName1 = GetCardFileName(player1MainCardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 7 then -- Player 1: 2nd Card
                    player1MainCardName2 = dealtCards[4]
                    player1MainCardFileName2 = GetCardFileName(player1MainCardName2)
                    player1H1CardName1 = dealtCards[1]
                    player1H1CardFileName1 = GetCardFileName(player1H1CardName1)
                    player1H2CardName1 = dealtCards[4]
                    player1H2CardFileName1 = GetCardFileName(player1H2CardName1)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 12 or turn == 31 then -- Player 1: 3rd Card or 3rd Card (Double)
                    player1MainCardName3 = dealtCards[6]
                    player1MainCardFileName3 = GetCardFileName(player1MainCardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 13 then -- Player 1: 4th Card
                    player1MainCardName4 = dealtCards[7]
                    player1MainCardFileName4 = GetCardFileName(player1MainCardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 14 then -- Player 1: 5th Card
                    player1MainCardName5 = dealtCards[8]
                    player1MainCardFileName5 = GetCardFileName(player1MainCardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 15 then -- Player 1: 6th Card
                    player1MainCardName6 = dealtCards[9]
                    player1MainCardFileName6 = GetCardFileName(player1MainCardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 16 then -- Player 1: 7th Card
                    player1MainCardName7 = dealtCards[10]
                    player1MainCardFileName7 = GetCardFileName(player1MainCardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 17 then  -- Player 1: 2nd Card (Split H1)
                    player1H1CardName2 = dealtCards[6]
                    player1H1CardFileName2 = GetCardFileName(player1H1CardName2)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 2
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 18 then -- Player 1: 2nd Card (Split H2)
                    player1H2CardName2 = dealtCards[7]
                    player1H2CardFileName2 = GetCardFileName(player1H2CardName2)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 19 or turn == 24 then -- Player 1: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player1H1CardName3 = dealtCards[8]
                    player1H1CardFileName3 = GetCardFileName(player1H1CardName3)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 20 then -- Player 1: 4th Card (Split H1)
                    player1H1CardName4 = dealtCards[9]
                    player1H1CardFileName4 = GetCardFileName(player1H1CardName4)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 21 then -- Player 1: 5th Card (Split H1)
                    player1H1CardName5 = dealtCards[10]
                    player1H1CardFileName5 = GetCardFileName(player1H1CardName5)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 22 then -- Player 1: 6th Card (Split H1)
                    player1H1CardName6 = dealtCards[11]
                    player1H1CardFileName6 = GetCardFileName(player1H1CardName6)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 23 then -- Player 1: 7th Card (Split H1)
                    player1H1CardName7 = dealtCards[12]
                    player1H1CardFileName7 = GetCardFileName(player1H1CardName7)
                    player1NumberOfCardsH1 = player1NumberOfCardsH1 + 1
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 25 or turn == 30 then -- Player 1: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player1H2CardName3 = dealtCards[player1NumberOfCardsH1 + 8]
                    player1H2CardFileName3 = GetCardFileName(player1H2CardName3)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 26 then -- Player 1: 4th Card (Split H2)
                    player1H2CardName4 = dealtCards[player1NumberOfCardsH1 + 9]
                    player1H2CardFileName4 = GetCardFileName(player1H2CardName4)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 27 then -- Player 1: 5th Card (Split H2)
                    player1H2CardName5 = dealtCards[player1NumberOfCardsH1 + 10]
                    player1H2CardFileName5 = GetCardFileName(player1H2CardName5)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 28 then -- Player 1: 6th Card (Split H2)
                    player1H2CardName6 = dealtCards[player1NumberOfCardsH1 + 11]
                    player1H2CardFileName6 = GetCardFileName(player1H2CardName6)
                    player1NumberOfCards = player1NumberOfCards + 1
                elseif turn == 29 then -- Player 1: 7th Card (Split H2)
                    player1H2CardName7 = dealtCards[player1NumberOfCardsH1 + 12]
                    player1H2CardFileName7 = GetCardFileName(player1H2CardName7)
                    player1NumberOfCards = player1NumberOfCards + 1
                end
            end

            -- >> MAIN HAND <<
            -- >> MAIN HAND <<

            player1dealtCardsFrame.player1MainCardImage1:SetTexture(nil)
            player1dealtCardsFrame.player1MainCardImage1:Hide()
            player1dealtCardsFrame.player1MainCardImage2:SetTexture(nil)
            player1dealtCardsFrame.player1MainCardImage2:Hide()
            player1dealtCardsFrame.player1MainCardImage3:SetTexture(nil)
            player1dealtCardsFrame.player1MainCardImage3:Hide()
            player1dealtCardsFrame.player1MainCardImage4:SetTexture(nil)
            player1dealtCardsFrame.player1MainCardImage4:Hide()
            player1dealtCardsFrame.player1MainCardImage5:SetTexture(nil)
            player1dealtCardsFrame.player1MainCardImage5:Hide()
            player1dealtCardsFrame.player1MainCardImage6:SetTexture(nil)
            player1dealtCardsFrame.player1MainCardImage6:Hide()
            player1dealtCardsFrame.player1MainCardImage7:SetTexture(nil)
            player1dealtCardsFrame.player1MainCardImage7:Hide()
            
            if player1MainCardName1 and player1MainCardFileName1 then
                player1dealtCardsFrame.player1MainCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1MainCardFileName1)
                player1dealtCardsFrame.player1MainCardImage1:Show()
                player1dealtCardsFrame.playerFirstCardText:Show()
            end
            if player1MainCardName2 and player1MainCardFileName2 then
                player1dealtCardsFrame.player1MainCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1MainCardFileName2)
                player1dealtCardsFrame.player1MainCardImage2:Show()
                player1dealtCardsFrame.playerSecondCardText:Show()
            end
            if player1MainCardName3 and player1MainCardFileName3 then
                player1dealtCardsFrame.player1MainCardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1MainCardFileName3)
                player1dealtCardsFrame.player1MainCardImage3:Show()
                player1dealtCardsFrame.playerThirdCardText:Show()
            end
            if player1MainCardName4 and player1MainCardFileName4 then
                player1dealtCardsFrame.player1MainCardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1MainCardFileName4)
                player1dealtCardsFrame.player1MainCardImage4:Show()
                player1dealtCardsFrame.playerFourthCardText:Show()
            end
            if player1MainCardName5 and player1MainCardFileName5 then
                player1dealtCardsFrame.player1MainCardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1MainCardFileName5)
                player1dealtCardsFrame.player1MainCardImage5:Show()
                player1dealtCardsFrame.playerFifthCardText:Show()
            end
            if player1MainCardName6 and player1MainCardFileName6 then
                player1dealtCardsFrame.player1MainCardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1MainCardFileName6)
                player1dealtCardsFrame.player1MainCardImage6:Show()
                player1dealtCardsFrame.playerSixthCardText:Show()
            end
            if player1MainCardName7 and player1MainCardFileName7 then
                player1dealtCardsFrame.player1MainCardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1MainCardFileName7)
                player1dealtCardsFrame.player1MainCardImage7:Show()
                player1dealtCardsFrame.playerSeventhCardText:Show()
            end

            -- >> SPLIT HAND 1 <<
            -- >> SPLIT HAND 1 <<

            player1dealtCardsFrameSplitH1.player1H1CardImage1:SetTexture(nil)
            player1dealtCardsFrameSplitH1.player1H1CardImage1:Hide()
            player1dealtCardsFrameSplitH1.player1H1CardImage2:SetTexture(nil)
            player1dealtCardsFrameSplitH1.player1H1CardImage2:Hide()
            player1dealtCardsFrameSplitH1.player1H1CardImage3:SetTexture(nil)
            player1dealtCardsFrameSplitH1.player1H1CardImage3:Hide()
            player1dealtCardsFrameSplitH1.player1H1CardImage4:SetTexture(nil)
            player1dealtCardsFrameSplitH1.player1H1CardImage4:Hide()
            player1dealtCardsFrameSplitH1.player1H1CardImage5:SetTexture(nil)
            player1dealtCardsFrameSplitH1.player1H1CardImage5:Hide()
            player1dealtCardsFrameSplitH1.player1H1CardImage6:SetTexture(nil)
            player1dealtCardsFrameSplitH1.player1H1CardImage6:Hide()
            player1dealtCardsFrameSplitH1.player1H1CardImage7:SetTexture(nil)
            player1dealtCardsFrameSplitH1.player1H1CardImage7:Hide()

            if player1H1CardName1 and player1H1CardFileName1 then
                player1dealtCardsFrameSplitH1.player1H1CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H1CardFileName1)
                player1dealtCardsFrameSplitH1.player1H1CardImage1:Show()
                player1dealtCardsFrameSplitH1.playerFirstCardText:Show()
            end
            if player1H1CardName2 and player1H1CardFileName2 then
                player1dealtCardsFrameSplitH1.player1H1CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H1CardFileName2)
                player1dealtCardsFrameSplitH1.player1H1CardImage2:Show()
                player1dealtCardsFrameSplitH1.playerSecondCardText:Show()
            end
            if player1H1CardName3 and player1H1CardFileName3 then
                player1dealtCardsFrameSplitH1.player1H1CardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H1CardFileName3)
                player1dealtCardsFrameSplitH1.player1H1CardImage3:Show()
                player1dealtCardsFrameSplitH1.playerThirdCardText:Show()
            end
            if player1H1CardName4 and player1H1CardFileName4 then
                player1dealtCardsFrameSplitH1.player1H1CardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H1CardFileName4)
                player1dealtCardsFrameSplitH1.player1H1CardImage4:Show()
                player1dealtCardsFrameSplitH1.playerFourthCardText:Show()
            end
            if player1H1CardName5 and player1H1CardFileName5 then
                player1dealtCardsFrameSplitH1.player1H1CardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H1CardFileName5)
                player1dealtCardsFrameSplitH1.player1H1CardImage5:Show()
                player1dealtCardsFrameSplitH1.playerFifthCardText:Show()
            end
            if player1H1CardName6 and player1H1CardFileName6 then
                player1dealtCardsFrameSplitH1.player1H1CardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H1CardFileName6)
                player1dealtCardsFrameSplitH1.player1H1CardImage6:Show()
                player1dealtCardsFrameSplitH1.playerSixthCardText:Show()
            end
            if player1H1CardName7 and player1H1CardFileName7 then
                player1dealtCardsFrameSplitH1.player1H1CardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H1CardFileName7)
                player1dealtCardsFrameSplitH1.player1H1CardImage7:Show()
                player1dealtCardsFrameSplitH1.playerSeventhCardText:Show()
            end

            -- >> SPLIT HAND 2 <<
            -- >> SPLIT HAND 2 <<

            player1dealtCardsFrameSplitH2.player1H2CardImage1:SetTexture(nil)
            player1dealtCardsFrameSplitH2.player1H2CardImage1:Hide()
            player1dealtCardsFrameSplitH2.player1H2CardImage2:SetTexture(nil)
            player1dealtCardsFrameSplitH2.player1H2CardImage2:Hide()
            player1dealtCardsFrameSplitH2.player1H2CardImage3:SetTexture(nil)
            player1dealtCardsFrameSplitH2.player1H2CardImage3:Hide()
            player1dealtCardsFrameSplitH2.player1H2CardImage4:SetTexture(nil)
            player1dealtCardsFrameSplitH2.player1H2CardImage4:Hide()
            player1dealtCardsFrameSplitH2.player1H2CardImage5:SetTexture(nil)
            player1dealtCardsFrameSplitH2.player1H2CardImage5:Hide()
            player1dealtCardsFrameSplitH2.player1H2CardImage6:SetTexture(nil)
            player1dealtCardsFrameSplitH2.player1H2CardImage6:Hide()
            player1dealtCardsFrameSplitH2.player1H2CardImage7:SetTexture(nil)
            player1dealtCardsFrameSplitH2.player1H2CardImage7:Hide()

            if player1H2CardName1 and player1H2CardFileName1 then
                player1dealtCardsFrameSplitH2.player1H2CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H2CardFileName1)
                player1dealtCardsFrameSplitH2.player1H2CardImage1:Show()
                player1dealtCardsFrameSplitH2.playerFirstCardText:Show()
            end
            if player1H2CardName2 and player1H2CardFileName2 then
                player1dealtCardsFrameSplitH2.player1H2CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H2CardFileName2)
                player1dealtCardsFrameSplitH2.player1H2CardImage2:Show()
                player1dealtCardsFrameSplitH2.playerSecondCardText:Show()
            end
            if player1H2CardName3 and player1H2CardFileName3 then
                player1dealtCardsFrameSplitH2.player1H2CardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H2CardFileName3)
                player1dealtCardsFrameSplitH2.player1H2CardImage3:Show()
                player1dealtCardsFrameSplitH2.playerThirdCardText:Show()
            end
            if player1H2CardName4 and player1H2CardFileName4 then
                player1dealtCardsFrameSplitH2.player1H2CardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H2CardFileName4)
                player1dealtCardsFrameSplitH2.player1H2CardImage4:Show()
                player1dealtCardsFrameSplitH2.playerFourthCardText:Show()
            end
            if player1H2CardName5 and player1H2CardFileName5 then
                player1dealtCardsFrameSplitH2.player1H2CardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H2CardFileName5)
                player1dealtCardsFrameSplitH2.player1H2CardImage5:Show()
                player1dealtCardsFrameSplitH2.playerFifthCardText:Show()
            end
            if player1H2CardName6 and player1H2CardFileName6 then
                player1dealtCardsFrameSplitH2.player1H2CardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H2CardFileName6)
                player1dealtCardsFrameSplitH2.player1H2CardImage6:Show()
                player1dealtCardsFrameSplitH2.playerSixthCardText:Show()
            end
            if player1H2CardName7 and player1H2CardFileName7 then
                player1dealtCardsFrameSplitH2.player1H2CardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1H2CardFileName7)
                player1dealtCardsFrameSplitH2.player1H2CardImage7:Show()
                player1dealtCardsFrameSplitH2.playerSeventhCardText:Show()
            end

        elseif unitName2 and string.find(message, unitName2) then

            player2dealtCardsFrame.notStartedYetText:Hide()
            
            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                if turn == 1 then -- Player 2: 1st Card
                    player2MainCardName1 = dealtCards[1]
                    player2MainCardFileName1 = GetCardFileName(player2MainCardName1)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 3 then -- Player 2: 2nd Card
                    player2MainCardName2 = dealtCards[3]
                    player2MainCardFileName2 = GetCardFileName(player2MainCardName2)
                    player2H1CardName1 = dealtCards[1]
                    player2H1CardFileName1 = GetCardFileName(player2H1CardName1)
                    player2H2CardName1 = dealtCards[3]
                    player2H2CardFileName1 = GetCardFileName(player2H2CardName1)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 4 or turn == 23 then -- Player 2: 3rd Card or 3rd Card (Double)
                    player2MainCardName3 = dealtCards[4]
                    player2MainCardFileName3 = GetCardFileName(player2MainCardName3)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 5 then -- Player 2: 4th Card
                    player2MainCardName4 = dealtCards[5]
                    player2MainCardFileName4 = GetCardFileName(player2MainCardName4)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 6 then -- Player 2: 5th Card
                    player2MainCardName5 = dealtCards[6]
                    player2MainCardFileName5 = GetCardFileName(player2MainCardName5)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 7 then -- Player 2: 6th Card
                    player2MainCardName6 = dealtCards[7]
                    player2MainCardFileName6 = GetCardFileName(player2MainCardName6)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 8 then -- Player 2: 7th Card
                    player2MainCardName7 = dealtCards[8]
                    player2MainCardFileName7 = GetCardFileName(player2MainCardName7)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 9 then  -- Player 2: 2nd Card (Split H1)
                    player2H1CardName2 = dealtCards[4]
                    player2H1CardFileName2 = GetCardFileName(player2H1CardName2)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 2
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 10 then -- Player 2: 2nd Card (Split H2)
                    player2H2CardName2 = dealtCards[5]
                    player2H2CardFileName2 = GetCardFileName(player2H2CardName2)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 11 or turn == 16 then -- Player 2: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player2H1CardName3 = dealtCards[6]
                    player2H1CardFileName3 = GetCardFileName(player2H1CardName3)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 12 then -- Player 2: 4th Card (Split H1)
                    player2H1CardName4 = dealtCards[7]
                    player2H1CardFileName4 = GetCardFileName(player2H1CardName4)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 13 then -- Player 2: 5th Card (Split H1)
                    player2H1CardName5 = dealtCards[8]
                    player2H1CardFileName5 = GetCardFileName(player2H1CardName5)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 14 then -- Player 2: 6th Card (Split H1)
                    player2H1CardName6 = dealtCards[9]
                    player2H1CardFileName6 = GetCardFileName(player2H1CardName6)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 15 then -- Player 2: 7th Card (Split H1)
                    player2H1CardName7 = dealtCards[10]
                    player2H1CardFileName7 = GetCardFileName(player2H1CardName7)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 17 or turn == 22 then -- Player 2: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player2H2CardName3 = dealtCards[player2NumberOfCardsH1 + 4]
                    player2H2CardFileName3 = GetCardFileName(player2H2CardName3)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 18 then -- Player 2: 4th Card (Split H2)
                    player2H2CardName4 = dealtCards[player2NumberOfCardsH1 + 5]
                    player2H2CardFileName4 = GetCardFileName(player2H2CardName4)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 19 then -- Player 2: 5th Card (Split H2)
                    player2H2CardName5 = dealtCards[player2NumberOfCardsH1 + 6]
                    player2H2CardFileName5 = GetCardFileName(player2H2CardName5)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 20 then -- Player 2: 6th Card (Split H2)
                    player2H2CardName6 = dealtCards[player2NumberOfCardsH1 + 7]
                    player2H2CardFileName6 = GetCardFileName(player2H2CardName6)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 21 then -- Player 2: 7th Card (Split H2)
                    player2H2CardName7 = dealtCards[player2NumberOfCardsH1 + 8]
                    player2H2CardFileName7 = GetCardFileName(player2H2CardName7)
                    player2NumberOfCards = player2NumberOfCards + 1
                end

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                if turn == 2 then -- Player 2: 1st Card
                    player2MainCardName1 = dealtCards[2]
                    player2MainCardFileName1 = GetCardFileName(player2MainCardName1)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 5 then -- Player 2: 2nd Card
                    player2MainCardName2 = dealtCards[5]
                    player2MainCardFileName2 = GetCardFileName(player2MainCardName2)
                    player2H1CardName1 = dealtCards[2]
                    player2H1CardFileName1 = GetCardFileName(player2H1CardName1)
                    player2H2CardName1 = dealtCards[5]
                    player2H2CardFileName1 = GetCardFileName(player2H2CardName1)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 26 or turn == 45 then -- Player 2: 3rd Card or 3rd Card (Double)
                    player2MainCardName3 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + 2]
                    player2MainCardFileName3 = GetCardFileName(player2MainCardName3)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 27 then -- Player 2: 4th Card
                    player2MainCardName4 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + 3]
                    player2MainCardFileName4 = GetCardFileName(player2MainCardName4)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 28 then -- Player 2: 5th Card
                    player2MainCardName5 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + 4]
                    player2MainCardFileName5 = GetCardFileName(player2MainCardName5)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 29 then -- Player 2: 6th Card
                    player2MainCardName6 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + 5]
                    player2MainCardFileName6 = GetCardFileName(player2MainCardName6)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 30 then -- Player 2: 7th Card
                    player2MainCardName7 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + 6]
                    player2MainCardFileName7 = GetCardFileName(player2MainCardName7)
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 31 then  -- Player 2: 2nd Card (Split H1)
                    player2H1CardName2 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards]
                    player2H1CardFileName2 = GetCardFileName(player2H1CardName2)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 2
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 32 then -- Player 2: 2nd Card (Split H2)
                    player2H2CardName2 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards + player2NumberOfCardsH1 - 1]
                    player2H2CardFileName2 = GetCardFileName(player2H2CardName2)
                    player2NumberOfCardsH2 = player2NumberOfCardsH2 + 2
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 33 or turn == 38 then -- Player 2: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player2H1CardName3 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards + 1]
                    player2H1CardFileName3 = GetCardFileName(player2H1CardName3)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 34 then -- Player 2: 4th Card (Split H1)
                    player2H1CardName4 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards + 2]
                    player2H1CardFileName4 = GetCardFileName(player2H1CardName4)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 35 then -- Player 2: 5th Card (Split H1)
                    player2H1CardName5 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards + 3]
                    player2H1CardFileName5 = GetCardFileName(player2H1CardName5)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 36 then -- Player 2: 6th Card (Split H1)
                    player2H1CardName6 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards + 4]
                    player2H1CardFileName6 = GetCardFileName(player2H1CardName6)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 37 then -- Player 2: 7th Card (Split H1)
                    player2H1CardName7 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards + 5]
                    player2H1CardFileName7 = GetCardFileName(player2H1CardName7)
                    player2NumberOfCardsH1 = player2NumberOfCardsH1 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 39 or turn == 44 then -- Player 2: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player2H2CardName3 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards + player2NumberOfCardsH1]
                    player2H2CardFileName3 = GetCardFileName(player2H2CardName3)
                    player2NumberOfCardsH2 = player2NumberOfCardsH2 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 40 then -- Player 2: 4th Card (Split H2)
                    player2H2CardName4 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards + player2NumberOfCardsH1 + 1]
                    player2H2CardFileName4 = GetCardFileName(player2H2CardName4)
                    player2NumberOfCardsH2 = player2NumberOfCardsH2 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 41 then -- Player 2: 5th Card (Split H2)
                    player2H2CardName5 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards + player2NumberOfCardsH1 + 2]
                    player2H2CardFileName5 = GetCardFileName(player2H2CardName5)
                    player2NumberOfCardsH2 = player2NumberOfCardsH2 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 42 then -- Player 2: 6th Card (Split H2)
                    player2H2CardName6 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards + player2NumberOfCardsH1 + 3]
                    player2H2CardFileName6 = GetCardFileName(player2H2CardName6)
                    player2NumberOfCardsH2 = player2NumberOfCardsH2 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                elseif turn == 43 then -- Player 2: 7th Card (Split H2)
                    player2H2CardName7 = dealtCards[player1NumberOfCards + player1NumberOfCardsH1 + player1NumberOfCardsH2 + player2NumberOfCards + player2NumberOfCardsH1 + 4]
                    player2H2CardFileName7 = GetCardFileName(player2H2CardName7)
                    player2NumberOfCardsH2 = player2NumberOfCardsH2 + 1
                    player2NumberOfCards = player2NumberOfCards + 1
                end

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                
            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            
            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
            
            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
            
            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
            
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
            
            end

            -- >> MAIN HAND <<
            -- >> MAIN HAND <<

            if player2MainCardName1 and player2MainCardFileName1 then
                player2dealtCardsFrame.player2MainCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2MainCardFileName1)
                player2dealtCardsFrame.player2MainCardImage1:Show()
                player2dealtCardsFrame.playerFirstCardText:Show()
            end
            if player2MainCardName2 and player2MainCardFileName2 then
                player2dealtCardsFrame.player2MainCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2MainCardFileName2)
                player2dealtCardsFrame.player2MainCardImage2:Show()
                player2dealtCardsFrame.playerSecondCardText:Show()
            end
            if player2MainCardName3 and player2MainCardFileName3 then
                player2dealtCardsFrame.player2MainCardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2MainCardFileName3)
                player2dealtCardsFrame.player2MainCardImage3:Show()
                player2dealtCardsFrame.playerThirdCardText:Show()
            end
            if player2MainCardName4 and player2MainCardFileName4 then
                player2dealtCardsFrame.player2MainCardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2MainCardFileName4)
                player2dealtCardsFrame.player2MainCardImage4:Show()
                player2dealtCardsFrame.playerFourthCardText:Show()
            end
            if player2MainCardName5 and player2MainCardFileName5 then
                player2dealtCardsFrame.player2MainCardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2MainCardFileName5)
                player2dealtCardsFrame.player2MainCardImage5:Show()
                player2dealtCardsFrame.playerFifthCardText:Show()
            end
            if player2MainCardName6 and player2MainCardFileName6 then
                player2dealtCardsFrame.player2MainCardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2MainCardFileName6)
                player2dealtCardsFrame.player2MainCardImage6:Show()
                player2dealtCardsFrame.playerSixthCardText:Show()
            end
            if player2MainCardName7 and player2MainCardFileName7 then
                player2dealtCardsFrame.player2MainCardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2MainCardFileName7)
                player2dealtCardsFrame.player2MainCardImage7:Show()
                player2dealtCardsFrame.playerSeventhCardText:Show()
            end

            -- >> SPLIT HAND 1 <<
            -- >> SPLIT HAND 1 <<

            if player2H1CardName1 and player2H1CardFileName1 then
                player2dealtCardsFrameSplitH1.player2H1CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H1CardFileName1)
                player2dealtCardsFrameSplitH1.player2H1CardImage1:Show()
                player2dealtCardsFrameSplitH1.playerFirstCardText:Show()
            end
            if player2H1CardName2 and player2H1CardFileName2 then
                player2dealtCardsFrameSplitH1.player2H1CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H1CardFileName2)
                player2dealtCardsFrameSplitH1.player2H1CardImage2:Show()
                player2dealtCardsFrameSplitH1.playerSecondCardText:Show()
            end
            if player2H1CardName3 and player2H1CardFileName3 then
                player2dealtCardsFrameSplitH1.player2H1CardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H1CardFileName3)
                player2dealtCardsFrameSplitH1.player2H1CardImage3:Show()
                player2dealtCardsFrameSplitH1.playerThirdCardText:Show()
            end
            if player2H1CardName4 and player2H1CardFileName4 then
                player2dealtCardsFrameSplitH1.player2H1CardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H1CardFileName4)
                player2dealtCardsFrameSplitH1.player2H1CardImage4:Show()
                player2dealtCardsFrameSplitH1.playerFourthCardText:Show()
            end
            if player2H1CardName5 and player2H1CardFileName5 then
                player2dealtCardsFrameSplitH1.player2H1CardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H1CardFileName5)
                player2dealtCardsFrameSplitH1.player2H1CardImage5:Show()
                player2dealtCardsFrameSplitH1.playerFifthCardText:Show()
            end
            if player2H1CardName6 and player2H1CardFileName6 then
                player2dealtCardsFrameSplitH1.player2H1CardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H1CardFileName6)
                player2dealtCardsFrameSplitH1.player2H1CardImage6:Show()
                player2dealtCardsFrameSplitH1.playerSixthCardText:Show()
            end
            if player2H1CardName7 and player2H1CardFileName7 then
                player2dealtCardsFrameSplitH1.player2H1CardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H1CardFileName7)
                player2dealtCardsFrameSplitH1.player2H1CardImage7:Show()
                player2dealtCardsFrameSplitH1.playerSeventhCardText:Show()
            end

            -- >> SPLIT HAND 2 <<
            -- >> SPLIT HAND 2 <<

            if player2H2CardName1 and player2H2CardFileName1 then
                player2dealtCardsFrameSplitH2.player2H2CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H2CardFileName1)
                player2dealtCardsFrameSplitH2.player2H2CardImage1:Show()
                player2dealtCardsFrameSplitH2.playerFirstCardText:Show()
            end
            if player2H2CardName2 and player2H2CardFileName2 then
                player2dealtCardsFrameSplitH2.player2H2CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H2CardFileName2)
                player2dealtCardsFrameSplitH2.player2H2CardImage2:Show()
                player2dealtCardsFrameSplitH2.playerSecondCardText:Show()
            end
            if player2H2CardName3 and player2H2CardFileName3 then
                player2dealtCardsFrameSplitH2.player2H2CardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H2CardFileName3)
                player2dealtCardsFrameSplitH2.player2H2CardImage3:Show()
                player2dealtCardsFrameSplitH2.playerThirdCardText:Show()
            end
            if player2H2CardName4 and player2H2CardFileName4 then
                player2dealtCardsFrameSplitH2.player2H2CardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H2CardFileName4)
                player2dealtCardsFrameSplitH2.player2H2CardImage4:Show()
                player2dealtCardsFrameSplitH2.playerFourthCardText:Show()
            end
            if player2H2CardName5 and player2H2CardFileName5 then
                player2dealtCardsFrameSplitH2.player2H2CardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H2CardFileName5)
                player2dealtCardsFrameSplitH2.player2H2CardImage5:Show()
                player2dealtCardsFrameSplitH2.playerFifthCardText:Show()
            end
            if player2H2CardName6 and player2H2CardFileName6 then
                player2dealtCardsFrameSplitH2.player2H2CardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H2CardFileName6)
                player2dealtCardsFrameSplitH2.player2H2CardImage6:Show()
                player2dealtCardsFrameSplitH2.playerSixthCardText:Show()
            end
            if player2H2CardName7 and player2H2CardFileName7 then
                player2dealtCardsFrameSplitH2.player2H2CardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2H2CardFileName7)
                player2dealtCardsFrameSplitH2.player2H2CardImage7:Show()
                player2dealtCardsFrameSplitH2.playerSeventhCardText:Show()
            end
        
        elseif unitName3 and string.find(message, unitName3) then

            player3dealtCardsFrame.notStartedYetText:Hide()
            
            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                if turn == 1 then -- Player 3: 1st Card
                    player3MainCardName1 = dealtCards[1]
                    player3MainCardFileName1 = GetCardFileName(player3MainCardName1)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 3 then -- Player 3: 2nd Card
                    player3MainCardName2 = dealtCards[3]
                    player3MainCardFileName2 = GetCardFileName(player3MainCardName2)
                    player3H1CardName1 = dealtCards[1]
                    player3H1CardFileName1 = GetCardFileName(player3H1CardName1)
                    player3H2CardName1 = dealtCards[3]
                    player3H2CardFileName1 = GetCardFileName(player3H2CardName1)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 4 or turn == 23 then -- Player 3: 3rd Card or 3rd Card (Double)
                    player3MainCardName3 = dealtCards[4]
                    player3MainCardFileName3 = GetCardFileName(player3MainCardName3)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 5 then -- Player 3: 4th Card
                    player3MainCardName4 = dealtCards[5]
                    player3MainCardFileName4 = GetCardFileName(player3MainCardName4)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 6 then -- Player 3: 5th Card
                    player3MainCardName5 = dealtCards[6]
                    player3MainCardFileName5 = GetCardFileName(player3MainCardName5)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 7 then -- Player 3: 6th Card
                    player3MainCardName6 = dealtCards[7]
                    player3MainCardFileName6 = GetCardFileName(player3MainCardName6)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 8 then -- Player 3: 7th Card
                    player3MainCardName7 = dealtCards[8]
                    player3MainCardFileName7 = GetCardFileName(player3MainCardName7)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 9 then  -- Player 3: 2nd Card (Split H1)
                    player3H1CardName2 = dealtCards[4]
                    player3H1CardFileName2 = GetCardFileName(player3H1CardName2)
                    player3NumberOfCardsH1 = player3NumberOfCardsH1 + 2
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 10 then -- Player 3: 2nd Card (Split H2)
                    player3H2CardName2 = dealtCards[5]
                    player3H2CardFileName2 = GetCardFileName(player3H2CardName2)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 11 or turn == 16 then -- Player 3: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player3H1CardName3 = dealtCards[6]
                    player3H1CardFileName3 = GetCardFileName(player3H1CardName3)
                    player3NumberOfCardsH1 = player3NumberOfCardsH1 + 1
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 12 then -- Player 3: 4th Card (Split H1)
                    player3H1CardName4 = dealtCards[7]
                    player3H1CardFileName4 = GetCardFileName(player3H1CardName4)
                    player3NumberOfCardsH1 = player3NumberOfCardsH1 + 1
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 13 then -- Player 3: 5th Card (Split H1)
                    player3H1CardName5 = dealtCards[8]
                    player3H1CardFileName5 = GetCardFileName(player3H1CardName5)
                    player3NumberOfCardsH1 = player3NumberOfCardsH1 + 1
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 14 then -- Player 3: 6th Card (Split H1)
                    player3H1CardName6 = dealtCards[9]
                    player3H1CardFileName6 = GetCardFileName(player3H1CardName6)
                    player3NumberOfCardsH1 = player3NumberOfCardsH1 + 1
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 15 then -- Player 3: 7th Card (Split H1)
                    player3H1CardName7 = dealtCards[10]
                    player3H1CardFileName7 = GetCardFileName(player3H1CardName7)
                    player3NumberOfCardsH1 = player3NumberOfCardsH1 + 1
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 17 or turn == 22 then -- Player 3: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player3H2CardName3 = dealtCards[player3NumberOfCardsH1 + 4]
                    player3H2CardFileName3 = GetCardFileName(player3H2CardName3)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 18 then -- Player 3: 4th Card (Split H2)
                    player3H2CardName4 = dealtCards[player3NumberOfCardsH1 + 5]
                    player3H2CardFileName4 = GetCardFileName(player3H2CardName4)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 19 then -- Player 3: 5th Card (Split H2)
                    player3H2CardName5 = dealtCards[player3NumberOfCardsH1 + 6]
                    player3H2CardFileName5 = GetCardFileName(player3H2CardName5)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 20 then -- Player 3: 6th Card (Split H2)
                    player3H2CardName6 = dealtCards[player3NumberOfCardsH1 + 7]
                    player3H2CardFileName6 = GetCardFileName(player3H2CardName6)
                    player3NumberOfCards = player3NumberOfCards + 1
                elseif turn == 21 then -- Player 3: 7th Card (Split H2)
                    player3H2CardName7 = dealtCards[player3NumberOfCardsH1 + 8]
                    player3H2CardFileName7 = GetCardFileName(player3H2CardName7)
                    player3NumberOfCards = player3NumberOfCards + 1
                end

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                
            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
            
            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
            
            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
            
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
            
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
            
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                
            end

            -- >> MAIN HAND <<
            -- >> MAIN HAND <<

            if player3MainCardName1 and player3MainCardFileName1 then
                player3dealtCardsFrame.player3MainCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3MainCardFileName1)
                player3dealtCardsFrame.player3MainCardImage1:Show()
                player3dealtCardsFrame.playerFirstCardText:Show()
            end
            if player3MainCardName2 and player3MainCardFileName2 then
                player3dealtCardsFrame.player3MainCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3MainCardFileName2)
                player3dealtCardsFrame.player3MainCardImage2:Show()
                player3dealtCardsFrame.playerSecondCardText:Show()
            end
            if player3MainCardName3 and player3MainCardFileName3 then
                player3dealtCardsFrame.player3MainCardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3MainCardFileName3)
                player3dealtCardsFrame.player3MainCardImage3:Show()
                player3dealtCardsFrame.playerThirdCardText:Show()
            end
            if player3MainCardName4 and player3MainCardFileName4 then
                player3dealtCardsFrame.player3MainCardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3MainCardFileName4)
                player3dealtCardsFrame.player3MainCardImage4:Show()
                player3dealtCardsFrame.playerFourthCardText:Show()
            end
            if player3MainCardName5 and player3MainCardFileName5 then
                player3dealtCardsFrame.player3MainCardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3MainCardFileName5)
                player3dealtCardsFrame.player3MainCardImage5:Show()
                player3dealtCardsFrame.playerFifthCardText:Show()
            end
            if player3MainCardName6 and player3MainCardFileName6 then
                player3dealtCardsFrame.player3MainCardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3MainCardFileName6)
                player3dealtCardsFrame.player3MainCardImage6:Show()
                player3dealtCardsFrame.playerSixthCardText:Show()
            end
            if player3MainCardName7 and player3MainCardFileName7 then
                player3dealtCardsFrame.player3MainCardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3MainCardFileName7)
                player3dealtCardsFrame.player3MainCardImage7:Show()
                player3dealtCardsFrame.playerSeventhCardText:Show()
            end

            -- >> SPLIT HAND 1 <<
            -- >> SPLIT HAND 1 <<

            if player3H1CardName1 and player3H1CardFileName1 then
                player3dealtCardsFrameSplitH1.player3H1CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H1CardFileName1)
                player3dealtCardsFrameSplitH1.player3H1CardImage1:Show()
                player3dealtCardsFrameSplitH1.playerFirstCardText:Show()
            end
            if player3H1CardName2 and player3H1CardFileName2 then
                player3dealtCardsFrameSplitH1.player3H1CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H1CardFileName2)
                player3dealtCardsFrameSplitH1.player3H1CardImage2:Show()
                player3dealtCardsFrameSplitH1.playerSecondCardText:Show()
            end
            if player3H1CardName3 and player3H1CardFileName3 then
                player3dealtCardsFrameSplitH1.player3H1CardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H1CardFileName3)
                player3dealtCardsFrameSplitH1.player3H1CardImage3:Show()
                player3dealtCardsFrameSplitH1.playerThirdCardText:Show()
            end
            if player3H1CardName4 and player3H1CardFileName4 then
                player3dealtCardsFrameSplitH1.player3H1CardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H1CardFileName4)
                player3dealtCardsFrameSplitH1.player3H1CardImage4:Show()
                player3dealtCardsFrameSplitH1.playerFourthCardText:Show()
            end
            if player3H1CardName5 and player3H1CardFileName5 then
                player3dealtCardsFrameSplitH1.player3H1CardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H1CardFileName5)
                player3dealtCardsFrameSplitH1.player3H1CardImage5:Show()
                player3dealtCardsFrameSplitH1.playerFifthCardText:Show()
            end
            if player3H1CardName6 and player3H1CardFileName6 then
                player3dealtCardsFrameSplitH1.player3H1CardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H1CardFileName6)
                player3dealtCardsFrameSplitH1.player3H1CardImage6:Show()
                player3dealtCardsFrameSplitH1.playerSixthCardText:Show()
            end
            if player3H1CardName7 and player3H1CardFileName7 then
                player3dealtCardsFrameSplitH1.player3H1CardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H1CardFileName7)
                player3dealtCardsFrameSplitH1.player3H1CardImage7:Show()
                player3dealtCardsFrameSplitH1.playerSeventhCardText:Show()
            end

            -- >> SPLIT HAND 2 <<
            -- >> SPLIT HAND 2 <<

            if player3H2CardName1 and player3H2CardFileName1 then
                player3dealtCardsFrameSplitH2.player3H2CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H2CardFileName1)
                player3dealtCardsFrameSplitH2.player3H2CardImage1:Show()
                player3dealtCardsFrameSplitH2.playerFirstCardText:Show()
            end
            if player3H2CardName2 and player3H2CardFileName2 then
                player3dealtCardsFrameSplitH2.player3H2CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H2CardFileName2)
                player3dealtCardsFrameSplitH2.player3H2CardImage2:Show()
                player3dealtCardsFrameSplitH2.playerSecondCardText:Show()
            end
            if player3H2CardName3 and player3H2CardFileName3 then
                player3dealtCardsFrameSplitH2.player3H2CardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H2CardFileName3)
                player3dealtCardsFrameSplitH2.player3H2CardImage3:Show()
                player3dealtCardsFrameSplitH2.playerThirdCardText:Show()
            end
            if player3H2CardName4 and player3H2CardFileName4 then
                player3dealtCardsFrameSplitH2.player3H2CardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H2CardFileName4)
                player3dealtCardsFrameSplitH2.player3H2CardImage4:Show()
                player3dealtCardsFrameSplitH2.playerFourthCardText:Show()
            end
            if player3H2CardName5 and player3H2CardFileName5 then
                player3dealtCardsFrameSplitH2.player3H2CardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H2CardFileName5)
                player3dealtCardsFrameSplitH2.player3H2CardImage5:Show()
                player3dealtCardsFrameSplitH2.playerFifthCardText:Show()
            end
            if player3H2CardName6 and player3H2CardFileName6 then
                player3dealtCardsFrameSplitH2.player3H2CardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H2CardFileName6)
                player3dealtCardsFrameSplitH2.player3H2CardImage6:Show()
                player3dealtCardsFrameSplitH2.playerSixthCardText:Show()
            end
            if player3H2CardName7 and player3H2CardFileName7 then
                player3dealtCardsFrameSplitH2.player3H2CardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3H2CardFileName7)
                player3dealtCardsFrameSplitH2.player3H2CardImage7:Show()
                player3dealtCardsFrameSplitH2.playerSeventhCardText:Show()
            end

        elseif unitName4 and string.find(message, unitName4) then

            player4dealtCardsFrame.notStartedYetText:Hide()
            
            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                if turn == 1 then -- Player 4: 1st Card
                    player4MainCardName1 = dealtCards[1]
                    player4MainCardFileName1 = GetCardFileName(player4MainCardName1)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 3 then -- Player 4: 2nd Card
                    player4MainCardName2 = dealtCards[3]
                    player4MainCardFileName2 = GetCardFileName(player4MainCardName2)
                    player4H1CardName1 = dealtCards[1]
                    player4H1CardFileName1 = GetCardFileName(player4H1CardName1)
                    player4H2CardName1 = dealtCards[3]
                    player4H2CardFileName1 = GetCardFileName(player4H2CardName1)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 4 or turn == 23 then -- Player 4: 3rd Card or 3rd Card (Double)
                    player4MainCardName3 = dealtCards[4]
                    player4MainCardFileName3 = GetCardFileName(player4MainCardName3)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 5 then -- Player 4: 4th Card
                    player4MainCardName4 = dealtCards[5]
                    player4MainCardFileName4 = GetCardFileName(player4MainCardName4)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 6 then -- Player 4: 5th Card
                    player4MainCardName5 = dealtCards[6]
                    player4MainCardFileName5 = GetCardFileName(player4MainCardName5)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 7 then -- Player 4: 6th Card
                    player4MainCardName6 = dealtCards[7]
                    player4MainCardFileName6 = GetCardFileName(player4MainCardName6)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 8 then -- Player 4: 7th Card
                    player4MainCardName7 = dealtCards[8]
                    player4MainCardFileName7 = GetCardFileName(player4MainCardName7)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 9 then  -- Player 4: 2nd Card (Split H1)
                    player4H1CardName2 = dealtCards[4]
                    player4H1CardFileName2 = GetCardFileName(player4H1CardName2)
                    player4NumberOfCardsH1 = player4NumberOfCardsH1 + 2
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 10 then -- Player 4: 2nd Card (Split H2)
                    player4H2CardName2 = dealtCards[5]
                    player4H2CardFileName2 = GetCardFileName(player4H2CardName2)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 11 or turn == 16 then -- Player 4: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player4H1CardName3 = dealtCards[6]
                    player4H1CardFileName3 = GetCardFileName(player4H1CardName3)
                    player4NumberOfCardsH1 = player4NumberOfCardsH1 + 1
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 12 then -- Player 4: 4th Card (Split H1)
                    player4H1CardName4 = dealtCards[7]
                    player4H1CardFileName4 = GetCardFileName(player4H1CardName4)
                    player4NumberOfCardsH1 = player4NumberOfCardsH1 + 1
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 13 then -- Player 4: 5th Card (Split H1)
                    player4H1CardName5 = dealtCards[8]
                    player4H1CardFileName5 = GetCardFileName(player4H1CardName5)
                    player4NumberOfCardsH1 = player4NumberOfCardsH1 + 1
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 14 then -- Player 4: 6th Card (Split H1)
                    player4H1CardName6 = dealtCards[9]
                    player4H1CardFileName6 = GetCardFileName(player4H1CardName6)
                    player4NumberOfCardsH1 = player4NumberOfCardsH1 + 1
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 15 then -- Player 4: 7th Card (Split H1)
                    player4H1CardName7 = dealtCards[10]
                    player4H1CardFileName7 = GetCardFileName(player4H1CardName7)
                    player4NumberOfCardsH1 = player4NumberOfCardsH1 + 1
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 17 or turn == 22 then -- Player 4: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player4H2CardName3 = dealtCards[player4NumberOfCardsH1 + 4]
                    player4H2CardFileName3 = GetCardFileName(player4H2CardName3)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 18 then -- Player 4: 4th Card (Split H2)
                    player4H2CardName4 = dealtCards[player4NumberOfCardsH1 + 5]
                    player4H2CardFileName4 = GetCardFileName(player4H2CardName4)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 19 then -- Player 4: 5th Card (Split H2)
                    player4H2CardName5 = dealtCards[player4NumberOfCardsH1 + 6]
                    player4H2CardFileName5 = GetCardFileName(player4H2CardName5)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 20 then -- Player 4: 6th Card (Split H2)
                    player4H2CardName6 = dealtCards[player4NumberOfCardsH1 + 7]
                    player4H2CardFileName6 = GetCardFileName(player4H2CardName6)
                    player4NumberOfCards = player4NumberOfCards + 1
                elseif turn == 21 then -- Player 4: 7th Card (Split H2)
                    player4H2CardName7 = dealtCards[player4NumberOfCardsH1 + 8]
                    player4H2CardFileName7 = GetCardFileName(player4H2CardName7)
                    player4NumberOfCards = player4NumberOfCards + 1
                end
            
            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
        
            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
            
            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
        
            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
            

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
        
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
        
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
        
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
        
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
        
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
        
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
        
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
    
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
    

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    

            end

            -- >> MAIN HAND <<
            -- >> MAIN HAND <<

            if player4MainCardName1 and player4MainCardFileName1 then
                player4dealtCardsFrame.player4MainCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4MainCardFileName1)
                player4dealtCardsFrame.player4MainCardImage1:Show()
                player4dealtCardsFrame.playerFirstCardText:Show()
            end
            if player4MainCardName2 and player4MainCardFileName2 then
                player4dealtCardsFrame.player4MainCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4MainCardFileName2)
                player4dealtCardsFrame.player4MainCardImage2:Show()
                player4dealtCardsFrame.playerSecondCardText:Show()
            end
            if player4MainCardName3 and player4MainCardFileName3 then
                player4dealtCardsFrame.player4MainCardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4MainCardFileName3)
                player4dealtCardsFrame.player4MainCardImage3:Show()
                player4dealtCardsFrame.playerThirdCardText:Show()
            end
            if player4MainCardName4 and player4MainCardFileName4 then
                player4dealtCardsFrame.player4MainCardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4MainCardFileName4)
                player4dealtCardsFrame.player4MainCardImage4:Show()
                player4dealtCardsFrame.playerFourthCardText:Show()
            end
            if player4MainCardName5 and player4MainCardFileName5 then
                player4dealtCardsFrame.player4MainCardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4MainCardFileName5)
                player4dealtCardsFrame.player4MainCardImage5:Show()
                player4dealtCardsFrame.playerFifthCardText:Show()
            end
            if player4MainCardName6 and player4MainCardFileName6 then
                player4dealtCardsFrame.player4MainCardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4MainCardFileName6)
                player4dealtCardsFrame.player4MainCardImage6:Show()
                player4dealtCardsFrame.playerSixthCardText:Show()
            end
            if player4MainCardName7 and player4MainCardFileName7 then
                player4dealtCardsFrame.player4MainCardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4MainCardFileName7)
                player4dealtCardsFrame.player4MainCardImage7:Show()
                player4dealtCardsFrame.playerSeventhCardText:Show()
            end

            -- >> SPLIT HAND 1 <<
            -- >> SPLIT HAND 1 <<

            if player4H1CardName1 and player4H1CardFileName1 then
                player4dealtCardsFrameSplitH1.player4H1CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H1CardFileName1)
                player4dealtCardsFrameSplitH1.player4H1CardImage1:Show()
                player4dealtCardsFrameSplitH1.playerFirstCardText:Show()
            end
            if player4H1CardName2 and player4H1CardFileName2 then
                player4dealtCardsFrameSplitH1.player4H1CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H1CardFileName2)
                player4dealtCardsFrameSplitH1.player4H1CardImage2:Show()
                player4dealtCardsFrameSplitH1.playerSecondCardText:Show()
            end
            if player4H1CardName3 and player4H1CardFileName3 then
                player4dealtCardsFrameSplitH1.player4H1CardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H1CardFileName3)
                player4dealtCardsFrameSplitH1.player4H1CardImage3:Show()
                player4dealtCardsFrameSplitH1.playerThirdCardText:Show()
            end
            if player4H1CardName4 and player4H1CardFileName4 then
                player4dealtCardsFrameSplitH1.player4H1CardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H1CardFileName4)
                player4dealtCardsFrameSplitH1.player4H1CardImage4:Show()
                player4dealtCardsFrameSplitH1.playerFourthCardText:Show()
            end
            if player4H1CardName5 and player4H1CardFileName5 then
                player4dealtCardsFrameSplitH1.player4H1CardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H1CardFileName5)
                player4dealtCardsFrameSplitH1.player4H1CardImage5:Show()
                player4dealtCardsFrameSplitH1.playerFifthCardText:Show()
            end
            if player4H1CardName6 and player4H1CardFileName6 then
                player4dealtCardsFrameSplitH1.player4H1CardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H1CardFileName6)
                player4dealtCardsFrameSplitH1.player4H1CardImage6:Show()
                player4dealtCardsFrameSplitH1.playerSixthCardText:Show()
            end
            if player4H1CardName7 and player4H1CardFileName7 then
                player4dealtCardsFrameSplitH1.player4H1CardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H1CardFileName7)
                player4dealtCardsFrameSplitH1.player4H1CardImage7:Show()
                player4dealtCardsFrameSplitH1.playerSeventhCardText:Show()
            end

            -- >> SPLIT HAND 2 <<
            -- >> SPLIT HAND 2 <<

            if player4H2CardName1 and player4H2CardFileName1 then
                player4dealtCardsFrameSplitH2.player4H2CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H2CardFileName1)
                player4dealtCardsFrameSplitH2.player4H2CardImage1:Show()
                player4dealtCardsFrameSplitH2.playerFirstCardText:Show()
            end
            if player4H2CardName2 and player4H2CardFileName2 then
                player4dealtCardsFrameSplitH2.player4H2CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H2CardFileName2)
                player4dealtCardsFrameSplitH2.player4H2CardImage2:Show()
                player4dealtCardsFrameSplitH2.playerSecondCardText:Show()
            end
            if player4H2CardName3 and player4H2CardFileName3 then
                player4dealtCardsFrameSplitH2.player4H2CardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H2CardFileName3)
                player4dealtCardsFrameSplitH2.player4H2CardImage3:Show()
                player4dealtCardsFrameSplitH2.playerThirdCardText:Show()
            end
            if player4H2CardName4 and player4H2CardFileName4 then
                player4dealtCardsFrameSplitH2.player4H2CardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H2CardFileName4)
                player4dealtCardsFrameSplitH2.player4H2CardImage4:Show()
                player4dealtCardsFrameSplitH2.playerFourthCardText:Show()
            end
            if player4H2CardName5 and player4H2CardFileName5 then
                player4dealtCardsFrameSplitH2.player4H2CardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H2CardFileName5)
                player4dealtCardsFrameSplitH2.player4H2CardImage5:Show()
                player4dealtCardsFrameSplitH2.playerFifthCardText:Show()
            end
            if player4H2CardName6 and player4H2CardFileName6 then
                player4dealtCardsFrameSplitH2.player4H2CardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H2CardFileName6)
                player4dealtCardsFrameSplitH2.player4H2CardImage6:Show()
                player4dealtCardsFrameSplitH2.playerSixthCardText:Show()
            end
            if player4H2CardName7 and player4H2CardFileName7 then
                player4dealtCardsFrameSplitH2.player4H2CardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4H2CardFileName7)
                player4dealtCardsFrameSplitH2.player4H2CardImage7:Show()
                player4dealtCardsFrameSplitH2.playerSeventhCardText:Show()
            end

        elseif unitName5 and string.find(message, unitName5) then

            player5dealtCardsFrame.notStartedYetText:Hide()
            
            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                if turn == 1 then -- Player 5: 1st Card
                    player5MainCardName1 = dealtCards[1]
                    player5MainCardFileName1 = GetCardFileName(player5MainCardName1)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 3 then -- Player 5: 2nd Card
                    player5MainCardName2 = dealtCards[3]
                    player5MainCardFileName2 = GetCardFileName(player5MainCardName2)
                    player5H1CardName1 = dealtCards[1]
                    player5H1CardFileName1 = GetCardFileName(player5H1CardName1)
                    player5H2CardName1 = dealtCards[3]
                    player5H2CardFileName1 = GetCardFileName(player5H2CardName1)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 4 or turn == 23 then -- Player 5: 3rd Card or 3rd Card (Double)
                    player5MainCardName3 = dealtCards[4]
                    player5MainCardFileName3 = GetCardFileName(player5MainCardName3)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 5 then -- Player 5: 4th Card
                    player5MainCardName4 = dealtCards[5]
                    player5MainCardFileName4 = GetCardFileName(player5MainCardName4)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 6 then -- Player 5: 5th Card
                    player5MainCardName5 = dealtCards[6]
                    player5MainCardFileName5 = GetCardFileName(player5MainCardName5)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 7 then -- Player 5: 6th Card
                    player5MainCardName6 = dealtCards[7]
                    player5MainCardFileName6 = GetCardFileName(player5MainCardName6)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 8 then -- Player 5: 7th Card
                    player5MainCardName7 = dealtCards[8]
                    player5MainCardFileName7 = GetCardFileName(player5MainCardName7)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 9 then  -- Player 5: 2nd Card (Split H1)
                    player5H1CardName2 = dealtCards[4]
                    player5H1CardFileName2 = GetCardFileName(player5H1CardName2)
                    player5NumberOfCardsH1 = player5NumberOfCardsH1 + 2
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 10 then -- Player 5: 2nd Card (Split H2)
                    player5H2CardName2 = dealtCards[5]
                    player5H2CardFileName2 = GetCardFileName(player5H2CardName2)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 11 or turn == 16 then -- Player 5: 3rd Card (Split H1) or 3rd Card (Double) (Split H1)
                    player5H1CardName3 = dealtCards[6]
                    player5H1CardFileName3 = GetCardFileName(player5H1CardName3)
                    player5NumberOfCardsH1 = player5NumberOfCardsH1 + 1
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 12 then -- Player 5: 4th Card (Split H1)
                    player5H1CardName4 = dealtCards[7]
                    player5H1CardFileName4 = GetCardFileName(player5H1CardName4)
                    player5NumberOfCardsH1 = player5NumberOfCardsH1 + 1
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 13 then -- Player 5: 5th Card (Split H1)
                    player5H1CardName5 = dealtCards[8]
                    player5H1CardFileName5 = GetCardFileName(player5H1CardName5)
                    player5NumberOfCardsH1 = player5NumberOfCardsH1 + 1
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 14 then -- Player 5: 6th Card (Split H1)
                    player5H1CardName6 = dealtCards[9]
                    player5H1CardFileName6 = GetCardFileName(player5H1CardName6)
                    player5NumberOfCardsH1 = player5NumberOfCardsH1 + 1
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 15 then -- Player 5: 7th Card (Split H1)
                    player5H1CardName7 = dealtCards[10]
                    player5H1CardFileName7 = GetCardFileName(player5H1CardName7)
                    player5NumberOfCardsH1 = player5NumberOfCardsH1 + 1
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 17 or turn == 22 then -- Player 5: 3rd Card (Split H2) or 3rd Card (Double) (Split H2)
                    player5H2CardName3 = dealtCards[player5NumberOfCardsH1 + 4]
                    player5H2CardFileName3 = GetCardFileName(player5H2CardName3)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 18 then -- Player 5: 4th Card (Split H2)
                    player5H2CardName4 = dealtCards[player5NumberOfCardsH1 + 5]
                    player5H2CardFileName4 = GetCardFileName(player5H2CardName4)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 19 then -- Player 5: 5th Card (Split H2)
                    player5H2CardName5 = dealtCards[player5NumberOfCardsH1 + 6]
                    player5H2CardFileName5 = GetCardFileName(player5H2CardName5)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 20 then -- Player 5: 6th Card (Split H2)
                    player5H2CardName6 = dealtCards[player5NumberOfCardsH1 + 7]
                    player5H2CardFileName6 = GetCardFileName(player5H2CardName6)
                    player5NumberOfCards = player5NumberOfCards + 1
                elseif turn == 21 then -- Player 5: 7th Card (Split H2)
                    player5H2CardName7 = dealtCards[player5NumberOfCardsH1 + 8]
                    player5H2CardFileName7 = GetCardFileName(player5H2CardName7)
                    player5NumberOfCards = player5NumberOfCards + 1
                end
            
            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
            
            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
            
            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
            
            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
        
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
            
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
            
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
            
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
            
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
            
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
            
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
            

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
    
            end

            -- >> MAIN HAND <<
            -- >> MAIN HAND <<

            if player5MainCardName1 and player5MainCardFileName1 then
                player5dealtCardsFrame.player5MainCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5MainCardFileName1)
                player5dealtCardsFrame.player5MainCardImage1:Show()
                player5dealtCardsFrame.playerFirstCardText:Show()
            end
            if player5MainCardName2 and player5MainCardFileName2 then
                player5dealtCardsFrame.player5MainCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5MainCardFileName2)
                player5dealtCardsFrame.player5MainCardImage2:Show()
                player5dealtCardsFrame.playerSecondCardText:Show()
            end
            if player5MainCardName3 and player5MainCardFileName3 then
                player5dealtCardsFrame.player5MainCardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5MainCardFileName3)
                player5dealtCardsFrame.player5MainCardImage3:Show()
                player5dealtCardsFrame.playerThirdCardText:Show()
            end
            if player5MainCardName4 and player5MainCardFileName4 then
                player5dealtCardsFrame.player5MainCardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5MainCardFileName4)
                player5dealtCardsFrame.player5MainCardImage4:Show()
                player5dealtCardsFrame.playerFourthCardText:Show()
            end
            if player5MainCardName5 and player5MainCardFileName5 then
                player5dealtCardsFrame.player5MainCardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5MainCardFileName5)
                player5dealtCardsFrame.player5MainCardImage5:Show()
                player5dealtCardsFrame.playerFifthCardText:Show()
            end
            if player5MainCardName6 and player5MainCardFileName6 then
                player5dealtCardsFrame.player5MainCardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5MainCardFileName6)
                player5dealtCardsFrame.player5MainCardImage6:Show()
                player5dealtCardsFrame.playerSixthCardText:Show()
            end
            if player5MainCardName7 and player5MainCardFileName7 then
                player5dealtCardsFrame.player5MainCardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5MainCardFileName7)
                player5dealtCardsFrame.player5MainCardImage7:Show()
                player5dealtCardsFrame.playerSeventhCardText:Show()
            end

            -- >> SPLIT HAND 1 <<
            -- >> SPLIT HAND 1 <<

            if player5H1CardName1 and player5H1CardFileName1 then
                player5dealtCardsFrameSplitH1.player5H1CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H1CardFileName1)
                player5dealtCardsFrameSplitH1.player5H1CardImage1:Show()
                player5dealtCardsFrameSplitH1.playerFirstCardText:Show()
            end
            if player5H1CardName2 and player5H1CardFileName2 then
                player5dealtCardsFrameSplitH1.player5H1CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H1CardFileName2)
                player5dealtCardsFrameSplitH1.player5H1CardImage2:Show()
                player5dealtCardsFrameSplitH1.playerSecondCardText:Show()
            end
            if player5H1CardName3 and player5H1CardFileName3 then
                player5dealtCardsFrameSplitH1.player5H1CardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H1CardFileName3)
                player5dealtCardsFrameSplitH1.player5H1CardImage3:Show()
                player5dealtCardsFrameSplitH1.playerThirdCardText:Show()
            end
            if player5H1CardName4 and player5H1CardFileName4 then
                player5dealtCardsFrameSplitH1.player5H1CardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H1CardFileName4)
                player5dealtCardsFrameSplitH1.player5H1CardImage4:Show()
                player5dealtCardsFrameSplitH1.playerFourthCardText:Show()
            end
            if player5H1CardName5 and player5H1CardFileName5 then
                player5dealtCardsFrameSplitH1.player5H1CardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H1CardFileName5)
                player5dealtCardsFrameSplitH1.player5H1CardImage5:Show()
                player5dealtCardsFrameSplitH1.playerFifthCardText:Show()
            end
            if player5H1CardName6 and player5H1CardFileName6 then
                player5dealtCardsFrameSplitH1.player5H1CardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H1CardFileName6)
                player5dealtCardsFrameSplitH1.player5H1CardImage6:Show()
                player5dealtCardsFrameSplitH1.playerSixthCardText:Show()
            end
            if player5H1CardName7 and player5H1CardFileName7 then
                player5dealtCardsFrameSplitH1.player5H1CardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H1CardFileName7)
                player5dealtCardsFrameSplitH1.player5H1CardImage7:Show()
                player5dealtCardsFrameSplitH1.playerSeventhCardText:Show()
            end

            -- >> SPLIT HAND 2 <<
            -- >> SPLIT HAND 2 <<

            if player5H2CardName1 and player5H2CardFileName1 then
                player5dealtCardsFrameSplitH2.player5H2CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H2CardFileName1)
                player5dealtCardsFrameSplitH2.player5H2CardImage1:Show()
                player5dealtCardsFrameSplitH2.playerFirstCardText:Show()
            end
            if player5H2CardName2 and player5H2CardFileName2 then
                player5dealtCardsFrameSplitH2.player5H2CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H2CardFileName2)
                player5dealtCardsFrameSplitH2.player5H2CardImage2:Show()
                player5dealtCardsFrameSplitH2.playerSecondCardText:Show()
            end
            if player5H2CardName3 and player5H2CardFileName3 then
                player5dealtCardsFrameSplitH2.player5H2CardImage3:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H2CardFileName3)
                player5dealtCardsFrameSplitH2.player5H2CardImage3:Show()
                player5dealtCardsFrameSplitH2.playerThirdCardText:Show()
            end
            if player5H2CardName4 and player5H2CardFileName4 then
                player5dealtCardsFrameSplitH2.player5H2CardImage4:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H2CardFileName4)
                player5dealtCardsFrameSplitH2.player5H2CardImage4:Show()
                player5dealtCardsFrameSplitH2.playerFourthCardText:Show()
            end
            if player5H2CardName5 and player5H2CardFileName5 then
                player5dealtCardsFrameSplitH2.player5H2CardImage5:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H2CardFileName5)
                player5dealtCardsFrameSplitH2.player5H2CardImage5:Show()
                player5dealtCardsFrameSplitH2.playerFifthCardText:Show()
            end
            if player5H2CardName6 and player5H2CardFileName6 then
                player5dealtCardsFrameSplitH2.player5H2CardImage6:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H2CardFileName6)
                player5dealtCardsFrameSplitH2.player5H2CardImage6:Show()
                player5dealtCardsFrameSplitH2.playerSixthCardText:Show()
            end
            if player5H2CardName7 and player5H2CardFileName7 then
                player5dealtCardsFrameSplitH2.player5H2CardImage7:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5H2CardFileName7)
                player5dealtCardsFrameSplitH2.player5H2CardImage7:Show()
                player5dealtCardsFrameSplitH2.playerSeventhCardText:Show()
            end

        end

    elseif string.find(message, "turned") then
        PlaySoundFile(soundFilePaths[32])
        playerFrame.player1TurnArrow:Hide()
        playerFrame.player2TurnArrow:Hide()
        playerFrame.player3TurnArrow:Hide()
        playerFrame.player4TurnArrow:Hide()
        playerFrame.player5TurnArrow:Hide()

    elseif string.find(message, "What is your decision") then
        if string.find(message, "(H1)") then
            if unitName1 and string.find(message, unitName1) then
                playerFrame.player1TurnArrow:Show()
                if playerName == unitName1 then
                    player1SplitHand1Turn()
                    player1SplitH1StartCountdown()
                end
            elseif unitName2 and string.find(message, unitName2) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Show()
                if playerName == unitName2 then
                    player2SplitHand1Turn()
                    player2SplitH1StartCountdown()
                end
            elseif unitName3 and string.find(message, unitName3) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Hide()
                playerFrame.player3TurnArrow:Show()
                if playerName == unitName3 then
                    player3SplitHand1Turn()
                    player3SplitH1StartCountdown()
                end
            elseif unitName4 and string.find(message, unitName4) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Hide()
                playerFrame.player3TurnArrow:Hide()
                playerFrame.player4TurnArrow:Show()
                if playerName == unitName4 then
                    player4SplitHand1Turn()
                    player4SplitH1StartCountdown()
                end
            elseif unitName5 and string.find(message, unitName5) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Hide()
                playerFrame.player3TurnArrow:Hide()
                playerFrame.player4TurnArrow:Hide()
                playerFrame.player5TurnArrow:Show()
                if playerName == unitName5 then
                    player5SplitHand1Turn()
                    player5SplitH1StartCountdown()
                end
            end
        elseif string.find(message, "(H2)") then
            if unitName1 and string.find(message, unitName1) then
                playerFrame.player1TurnArrow:Show()
                if playerName == unitName1 then
                    player1SplitHand2Turn()
                    player1SplitH2StartCountdown()
                end
            elseif unitName2 and string.find(message, unitName2) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Show()
                if playerName == unitName2 then
                    player2SplitHand2Turn()
                    player2SplitH2StartCountdown()
                end
            elseif unitName3 and string.find(message, unitName3) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Hide()
                playerFrame.player3TurnArrow:Show()
                if playerName == unitName3 then
                    player3SplitHand2Turn()
                    player3SplitH2StartCountdown()
                end
            elseif unitName4 and string.find(message, unitName4) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Hide()
                playerFrame.player3TurnArrow:Hide()
                playerFrame.player4TurnArrow:Show()
                if playerName == unitName4 then
                    player4SplitHand2Turn()
                    player4SplitH2StartCountdown()
                end
            elseif unitName5 and string.find(message, unitName5) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Hide()
                playerFrame.player3TurnArrow:Hide()
                playerFrame.player4TurnArrow:Hide()
                playerFrame.player5TurnArrow:Show()
                if playerName == unitName5 then
                    player5SplitHand2Turn()
                    player5SplitH2StartCountdown()
                end
            end
        end
        if not string.find(message, "(H1)") and not string.find(message, "(H2)") then
            if unitName1 and string.find(message, unitName1) then
                playerFrame.player1TurnArrow:Show()
                if playerName == unitName1 then
                    player1Turn()
                    player1StartCountdown()
                end
            elseif unitName2 and string.find(message, unitName2) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Show()
                if playerName == unitName2 then
                    player2Turn()
                    player2StartCountdown()
                end
            elseif unitName3 and string.find(message, unitName3) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Hide()
                playerFrame.player3TurnArrow:Show()
                if playerName == unitName3 then
                    player3Turn()
                    player3StartCountdown()
                end
            elseif unitName4 and string.find(message, unitName4) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Hide()
                playerFrame.player3TurnArrow:Hide()
                playerFrame.player4TurnArrow:Show()
                if playerName == unitName4 then
                    player4Turn()
                    player4StartCountdown()
                end
            elseif unitName5 and string.find(message, unitName5) then
                playerFrame.player1TurnArrow:Hide()
                playerFrame.player2TurnArrow:Hide()
                playerFrame.player3TurnArrow:Hide()
                playerFrame.player4TurnArrow:Hide()
                playerFrame.player5TurnArrow:Show()
                if playerName == unitName5 then
                    player5Turn()
                    player5StartCountdown()
                end
            end
        end
    

        




    -- >>> BLACKJACK <<<
    -- >>> BLACKJACK <<<
    -- >>> BLACKJACK <<<

    -- Dealer
    elseif string.find(message, "Dealer got Blackjack") then
        PlaySoundFile(soundFilePaths[111]) -- "Dealer - Blackjack"
        playerFrame.dealerCardTotalText:SetText("Blackjack")
        playerFrame.dealerCardTotalText:SetTextColor(1, 1, 0)

    -- Single Hand
    elseif string.find(message, "has Blackjack") and not string.find(message, "Hand 1") and not string.find(message, "Hand 2") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[38]) -- "Player 1 - Blackjack"
            playerFrame.player1CardTotalText:SetText("Blackjack")
            playerFrame.player1CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[52]) -- "Player 2 - Blackjack"
            playerFrame.player2CardTotalText:SetText("Blackjack")
            playerFrame.player2CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[66]) -- "Player 3 - Blackjack"
            playerFrame.player3CardTotalText:SetText("Blackjack")
            playerFrame.player3CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[80]) -- "Player 4 - Blackjack"
            playerFrame.player4CardTotalText:SetText("Blackjack")
            playerFrame.player4CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[94]) -- "Player 5 - Blackjack"
            playerFrame.player5CardTotalText:SetText("Blackjack")
            playerFrame.player5CardTotalText:SetTextColor(1, 1, 0)
        end

    -- Split Hand 1
    elseif string.find(message, "Hand 1") and string.find(message, "has Blackjack") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[38]) -- "Player 1 - Blackjack"
            playerFrame.player1SplitHand1CardTotalText:SetText("Blackjack")
            playerFrame.player1SplitHand1CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[52]) -- "Player 2 - Blackjack"
            playerFrame.player2SplitHand1CardTotalText:SetText("Blackjack")
            playerFrame.player2SplitHand1CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[66]) -- "Player 3 - Blackjack"
            playerFrame.player3SplitHand1CardTotalText:SetText("Blackjack")
            playerFrame.player3SplitHand1CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[80]) -- "Player 4 - Blackjack"
            playerFrame.player4SplitHand1CardTotalText:SetText("Blackjack")
            playerFrame.player4SplitHand1CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[94]) -- "Player 5 - Blackjack"
            playerFrame.player5SplitHand1CardTotalText:SetText("Blackjack")
            playerFrame.player5SplitHand1CardTotalText:SetTextColor(1, 1, 0)
        end

    -- Split Hand 2
    elseif string.find(message, "Hand 2") and string.find(message, "has Blackjack") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[38]) -- "Player 1 - Blackjack"
            playerFrame.player1SplitHand2CardTotalText:SetText("Blackjack")
            playerFrame.player1SplitHand2CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[52]) -- "Player 2 - Blackjack"
            playerFrame.player2SplitHand2CardTotalText:SetText("Blackjack")
            playerFrame.player2SplitHand2CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[66]) -- "Player 3 - Blackjack"
            playerFrame.player3SplitHand2CardTotalText:SetText("Blackjack")
            playerFrame.player3SplitHand2CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[80]) -- "Player 4 - Blackjack"
            playerFrame.player4SplitHand2CardTotalText:SetText("Blackjack")
            playerFrame.player4SplitHand2CardTotalText:SetTextColor(1, 1, 0)
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[94]) -- "Player 5 - Blackjack"
            playerFrame.player5SplitHand2CardTotalText:SetText("Blackjack")
            playerFrame.player5SplitHand2CardTotalText:SetTextColor(1, 1, 0)
        end 













    -- >>> RESULTS <<<
    -- >>> RESULTS <<<
    -- >>> RESULTS <<<

    -- Bust (Single Hand)
    elseif string.find(message, "has gone bust with a total of") and not string.find(message, "Hand 1") and not string.find(message, "Hand 2") then
        
        player1BeforeStandValue = playerFrame.player1CardTotalText:GetText()
        player2BeforeStandValue = playerFrame.player2CardTotalText:GetText()
        player3BeforeStandValue = playerFrame.player3CardTotalText:GetText()
        player4BeforeStandValue = playerFrame.player4CardTotalText:GetText()
        player5BeforeStandValue = playerFrame.player5CardTotalText:GetText()
        
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[42]) -- "Player 1 - Bust"
            player1MainBetAmount:SetTextColor(1, 0, 0)
            
            player1Hotstreak = 0
            player1HotStreakCheck()

            player1SessionWinAnnouncement()

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                turn = 23
                player1Loss()
                player1InsuranceLoss()

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                if player2BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                if player3BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                if player2BeforeStandValue == "Blackjack" then
                    turn = 47
                else
                    turn = 27
                end
            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                if player2BeforeStandValue == "Blackjack" then
                    turn = 47
                else
                    turn = 27
                end
            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                if player2BeforeStandValue == "Blackjack" then
                    turn = 47
                else
                    turn = 27
                end
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                if player3BeforeStandValue == "Blackjack" then
                    turn = 47
                else
                    turn = 27
                end
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                if player3BeforeStandValue == "Blackjack" then
                    turn = 47
                else
                    turn = 27
                end
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                if player4BeforeStandValue == "Blackjack" then
                    turn = 47
                else
                    turn = 27
                end

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                if player2BeforeStandValue == "Blackjack" then
                    turn = 49
                else
                    turn = 29
                end
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                if player2BeforeStandValue == "Blackjack" then
                    turn = 49
                else
                    turn = 29
                end
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                if player2BeforeStandValue == "Blackjack" then
                    turn = 49
                else
                    turn = 29
                end
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                if player3BeforeStandValue == "Blackjack" then
                    turn = 49
                else
                    turn = 29
                end

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                if player2BeforeStandValue == "Blackjack" then
                    turn = 51
                else
                    turn = 31
                end
            end

        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[56]) -- "Player 2 - Bust"
            player2MainBetAmount:SetTextColor(1, 0, 0)
            
            player2Hotstreak = 0
            player2HotStreakCheck()

            player2SessionWinAnnouncement()

            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                turn = 23
                player2Loss()
                player2InsuranceLoss()

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                turn = 45
            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                if player3BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                if player3BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                if player3BeforeStandValue == "Blackjack" then
                    turn = 47
                else
                    turn = 27
                end
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                if player3BeforeStandValue == "Blackjack" then
                    turn = 47
                else
                    turn = 27
                end
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                if player4BeforeStandValue == "Blackjack" then
                    turn = 47
                else
                    turn = 27
                end

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                if player3BeforeStandValue == "Blackjack" then
                    turn = 69
                else
                    turn = 49
                end
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                if player3BeforeStandValue == "Blackjack" then
                    turn = 69
                else
                    turn = 49
                end
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                if player4BeforeStandValue == "Blackjack" then
                    turn = 69
                else
                    turn = 49
                end
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                if player3BeforeStandValue == "Blackjack" then
                    turn = 49
                else
                    turn = 29
                end

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                if player3BeforeStandValue == "Blackjack" then
                    turn = 71
                else
                    turn = 51
                end
            end

        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[70]) -- "Player 3 - Bust"
            player3MainBetAmount:SetTextColor(1, 0, 0)
            
            player3Hotstreak = 0
            player3HotStreakCheck()

            player3SessionWinAnnouncement()

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                turn = 23
                player3Loss()
                player3InsuranceLoss()

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                turn = 45
            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                turn = 45
            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                if player4BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end
            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                turn = 67
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                if player4BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                if player4BeforeStandValue == "Blackjack" then
                    turn = 47
                else
                    turn = 27
                end

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                if player4BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                if player4BeforeStandValue == "Blackjack" then
                    turn = 69
                else
                    turn = 49
                end
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                if player4BeforeStandValue == "Blackjack" then
                    turn = 69
                else
                    turn = 49
                end

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                if player4BeforeStandValue == "Blackjack" then
                    turn = 91
                else
                    turn = 71
                end

            end

        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[84]) -- "Player 4 - Bust"
            player4MainBetAmount:SetTextColor(1, 0, 0)
            
            player4Hotstreak = 0
            player4HotStreakCheck()

            player4SessionWinAnnouncement()

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                turn = 23
                player4Loss()
                player4InsuranceLoss()

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                turn = 45
            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                turn = 45
            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                turn = 45
            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                if player5BeforeStandValue == "Blackjack" then
                    turn = 45
                else
                    turn = 25
                end

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                turn = 67
            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                turn = 67
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 67
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                if player5BeforeStandValue == "Blackjack" then
                    turn = 67
                else
                    turn = 47
                end

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                turn = 89
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                if player5BeforeStandValue == "Blackjack" then
                    turn = 89
                else
                    turn = 69
                end

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                if player5BeforeStandValue == "Blackjack" then
                    turn = 111
                else
                    turn = 91
                end
            end

        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[98]) -- "Player 5 - Bust"
            player5MainBetAmount:SetTextColor(1, 0, 0)

            player5Hotstreak = 0
            player5HotStreakCheck()

            player5SessionWinAnnouncement()

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                turn = 23
                player5Loss()
                player5InsuranceLoss()

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                turn = 45
            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                turn = 45
            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                turn = 45
            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                turn = 45

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                turn = 67
            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                turn = 67
            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                turn = 67
            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 67
            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 67
            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 67

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                turn = 89
            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                turn = 89
            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                turn = 89
            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 89

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                turn = 111
            end
        end

    -- Bust (Split Hand 1)
    elseif string.find(message, "has gone bust with a total of") and string.find(message, "Hand 1") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[42]) -- "Player 1 - Bust"
            player1SplitH1BetAmount:SetTextColor(1, 0, 0)
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[56]) -- "Player 2 - Bust"
            player2SplitH1BetAmount:SetTextColor(1, 0, 0)
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[70]) -- "Player 3 - Bust"
            player3SplitH1BetAmount:SetTextColor(1, 0, 0)
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[84]) -- "Player 4 - Bust"
            player4SplitH1BetAmount:SetTextColor(1, 0, 0)
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[98]) -- "Player 5 - Bust"
            player5SplitH1BetAmount:SetTextColor(1, 0, 0)
        end

    -- Bust (Split Hand 2)
    elseif string.find(message, "has gone bust with a total of") and string.find(message, "Hand 2") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[42]) -- "Player 1 - Bust"
            player1SplitH2BetAmount:SetTextColor(1, 0, 0)
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[56]) -- "Player 2 - Bust"
            player2SplitH2BetAmount:SetTextColor(1, 0, 0)
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[70]) -- "Player 3 - Bust"
            player3SplitH2BetAmount:SetTextColor(1, 0, 0)
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[84]) -- "Player 4 - Bust"
            player4SplitH2BetAmount:SetTextColor(1, 0, 0)
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[98]) -- "Player 5 - Bust"
            player5SplitH2BetAmount:SetTextColor(1, 0, 0)
        end


    -- Win (Single Hand)
    elseif string.find(message, "has won this round") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[39]) -- "Player 1 - Win"
            player1MainBetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player1CardTotalText:GetText() == "Blackjack" then
                player1BJWin()
            else
                player1Win()
            end

            player1SessionWinAnnouncement()

            player1Hotstreak = player1Hotstreak + 1
            player1HotStreakCheck()

        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[53]) -- "Player 2 - Win"
            player2MainBetAmount:SetTextColor(0, 1, 0)

            if playerFrame.player2CardTotalText:GetText() == "Blackjack" then
                player2BJWin()
            else
                player2Win()
            end

            player2SessionWinAnnouncement()

            player2Hotstreak = player2Hotstreak + 1
            player2HotStreakCheck()

        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[67]) -- "Player 3 - Win"
            player3MainBetAmount:SetTextColor(0, 1, 0)

            if playerFrame.player3CardTotalText:GetText() == "Blackjack" then
                player3BJWin()
            else
                player3Win()
            end

            player3SessionWinAnnouncement()

            player3Hotstreak = player3Hotstreak + 1
            player3HotStreakCheck()

        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[81]) -- "Player 4 - Win"
            player4MainBetAmount:SetTextColor(0, 1, 0)

            if playerFrame.player4CardTotalText:GetText() == "Blackjack" then
                player4BJWin()
            else
                player4Win()
            end

            player4SessionWinAnnouncement()

            player4Hotstreak = player4Hotstreak + 1
            player4HotStreakCheck()

        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[95]) -- "Player 5 - Win"
            player5MainBetAmount:SetTextColor(0, 1, 0)

            if playerFrame.player5CardTotalText:GetText() == "Blackjack" then
                player5BJWin()
            else
                player5Win()
            end

            player5SessionWinAnnouncement()

            player5Hotstreak = player5Hotstreak + 1
            player5HotStreakCheck()

        end

    -- Push (Single Hand)
    elseif string.find(message, "has pushed this round") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[40]) -- "Player 1 - Push"
            player1MainBetAmount:SetTextColor(0.2, 0.7, 1)
            player1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player1InsuranceWin()
            else
                player1InsuranceLoss()
            end

            player1SessionWinAnnouncement()

        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[54]) -- "Player 2 - Push"
            player2MainBetAmount:SetTextColor(0.2, 0.7, 1)
            player2Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player2InsuranceWin()
            else
                player2InsuranceLoss()
            end

            player2SessionWinAnnouncement()

        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[68]) -- "Player 3 - Push"
            player3MainBetAmount:SetTextColor(0.2, 0.7, 1)
            player3Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player3InsuranceWin()
            else
                player3InsuranceLoss()
            end

            player3SessionWinAnnouncement()

        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[82]) -- "Player 4 - Push"
            player4MainBetAmount:SetTextColor(0.2, 0.7, 1)
            player4Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player4InsuranceWin()
            else
                player4InsuranceLoss()
            end

            player4SessionWinAnnouncement()

        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[96]) -- "Player 5 - Push"
            player5MainBetAmount:SetTextColor(0.2, 0.7, 1)
            player5Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player5InsuranceWin()
            else
                player5InsuranceLoss()
            end

            player5SessionWinAnnouncement()

        end
        

    -- Loss (Single Hand)
    elseif string.find(message, "has lost this round") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[41]) -- "Player 1 - Loss"
            player1MainBetAmount:SetTextColor(1, 0, 0)
            player1Loss()
            
            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player1InsuranceWin()
            else
                player1InsuranceLoss()
            end

            player1SessionWinAnnouncement()

            player1Hotstreak = 0
            player1HotStreakCheck()

        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[55]) -- "Player 2 - Loss"
            player2MainBetAmount:SetTextColor(1, 0, 0)
            player2Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player2InsuranceWin()
            else
                player2InsuranceLoss()
            end

            player2SessionWinAnnouncement()

            player2Hotstreak = 0
            player2HotStreakCheck()

        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[69]) -- "Player 3 - Loss"
            player3MainBetAmount:SetTextColor(1, 0, 0)
            player3Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player3InsuranceWin()
            else
                player3InsuranceLoss()
            end

            player3SessionWinAnnouncement()

            player3Hotstreak = 0
            player3HotStreakCheck()

        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[83]) -- "Player 4 - Loss"
            player4MainBetAmount:SetTextColor(1, 0, 0)
            player4Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player4InsuranceWin()
            else
                player4InsuranceLoss()
            end

            player4SessionWinAnnouncement()

            player4Hotstreak = 0
            player4HotStreakCheck()

        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[97]) -- "Player 5 - Loss"
            player5MainBetAmount:SetTextColor(1, 0, 0)
            player5Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player5InsuranceWin()
            else
                player5InsuranceLoss()
            end

            player5SessionWinAnnouncement()

            player5Hotstreak = 0
            player5HotStreakCheck()

        end
        

    -- Win/Win (Split Hand)
    elseif string.find(message, "has won both Hand 1 and Hand 2") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[43]) -- "Player 1 - H1 Win, H2 Win"
            player1SplitH1BetAmount:SetTextColor(0, 1, 0)
            player1SplitH2BetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                player1SplitH2BJ()
            else
                player1SplitH2Win()
            end

            if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                player1SplitH1BJ()
            else
                player1SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player1InsuranceWin()
            else
                player1InsuranceLoss()
            end

            player1SessionWinAnnouncement()

            player1Hotstreak = player1Hotstreak + 2
            player1HotStreakCheck()
            
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[57]) -- "Player 2 - H1 Win, H2 Win"
            player2SplitH1BetAmount:SetTextColor(0, 1, 0)
            player2SplitH2BetAmount:SetTextColor(0, 1, 0)

            if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                player2SplitH2BJ()
            else
                player2SplitH2Win()
            end

            if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                player2SplitH1BJ()
            else
                player2SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player2InsuranceWin()
            else
                player2InsuranceLoss()
            end

            player2SessionWinAnnouncement()

            player2Hotstreak = player2Hotstreak + 2
            player2HotStreakCheck()
            
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[71]) -- "Player 3 - H1 Win, H2 Win"
            player3SplitH1BetAmount:SetTextColor(0, 1, 0)
            player3SplitH2BetAmount:SetTextColor(0, 1, 0)

            if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                player3SplitH2BJ()
            else
                player3SplitH2Win()
            end

            if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                player3SplitH1BJ()
            else
                player3SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player3InsuranceWin()
            else
                player3InsuranceLoss()
            end

            player3SessionWinAnnouncement()

            player3Hotstreak = player3Hotstreak + 2
            player3HotStreakCheck()
            
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[85]) -- "Player 4 - H1 Win, H2 Win"
            player4SplitH1BetAmount:SetTextColor(0, 1, 0)
            player4SplitH2BetAmount:SetTextColor(0, 1, 0)

            if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                player4SplitH2BJ()
            else
                player4SplitH2Win()
            end

            if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                player4SplitH1BJ()
            else
                player4SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player4InsuranceWin()
            else
                player4InsuranceLoss()
            end

            player4SessionWinAnnouncement()

            player4Hotstreak = player4Hotstreak + 2
            player4HotStreakCheck()
            
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[99]) -- "Player 5 - H1 Win, H2 Win"
            player5SplitH1BetAmount:SetTextColor(0, 1, 0)
            player5SplitH2BetAmount:SetTextColor(0, 1, 0)

            if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                player5SplitH2BJ()
            else
                player5SplitH2Win()
            end

            if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                player5SplitH1BJ()
            else
                player5SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player5InsuranceWin()
            else
                player5InsuranceLoss()
            end

            player5SessionWinAnnouncement()

            player5Hotstreak = player5Hotstreak + 2
            player5HotStreakCheck()
            
        end

    -- Win/Push (Split Hand)
    elseif string.find(message, "has won Hand 1 and pushes on Hand 2") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[44]) -- "Player 1 - H1 Win, H2 Push"
            player1SplitH1BetAmount:SetTextColor(0, 1, 0)
            player1SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player1SplitH2Push()
            
            if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                player1SplitH1BJ()
            else
                player1SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player1InsuranceWin()
            else
                player1InsuranceLoss()
            end

            player1SessionWinAnnouncement()

            player1Hotstreak = player1Hotstreak + 1
            player1HotStreakCheck()

        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[58]) -- "Player 2 - H1 Win, H2 Push"
            player2SplitH1BetAmount:SetTextColor(0, 1, 0)
            player2SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player2SplitH2Push()

            if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                player2SplitH1BJ()
            else
                player2SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player2InsuranceWin()
            else
                player2InsuranceLoss()
            end

            player2SessionWinAnnouncement()

            player2Hotstreak = player2Hotstreak + 1
            player2HotStreakCheck()

        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[72]) -- "Player 3 - H1 Win, H2 Push"
            player3SplitH1BetAmount:SetTextColor(0, 1, 0)
            player3SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player3SplitH2Push()

            if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                player3SplitH1BJ()
            else
                player3SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player3InsuranceWin()
            else
                player3InsuranceLoss()
            end

            player3SessionWinAnnouncement()

            player3Hotstreak = player3Hotstreak + 1
            player3HotStreakCheck()

        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[86]) -- "Player 4 - H1 Win, H2 Push"
            player4SplitH1BetAmount:SetTextColor(0, 1, 0)
            player4SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player4SplitH2Push()

            if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                player4SplitH1BJ()
            else
                player4SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player4InsuranceWin()
            else
                player4InsuranceLoss()
            end

            player4SessionWinAnnouncement()

            player4Hotstreak = player4Hotstreak + 1
            player4HotStreakCheck()

        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[100]) -- "Player 5 - H1 Win, H2 Push"
            player5SplitH1BetAmount:SetTextColor(0, 1, 0)
            player5SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player5SplitH2Push()

            if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                player5SplitH1BJ()
            else
                player5SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player5InsuranceWin()
            else
                player5InsuranceLoss()
            end

            player5SessionWinAnnouncement()

            player5Hotstreak = player5Hotstreak + 1
            player5HotStreakCheck()

        end

    -- Win/Loss (Split Hand)
    elseif string.find(message, "has won Hand 1 and lost Hand 2") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[45]) -- "Player 1 - H1 Win, H2 Loss"
            player1SplitH1BetAmount:SetTextColor(0, 1, 0)
            player1SplitH2BetAmount:SetTextColor(1, 0, 0)
            player1SplitH2Loss()
            
            if playerFrame.player1SplitHand1CardTotalText:GetText() == "Blackjack" then
                player1SplitH1BJ()
            else
                player1SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player1InsuranceWin()
            else
                player1InsuranceLoss()
            end

            player1SessionWinAnnouncement()

            player1Hotstreak = 0
            player1HotStreakCheck()
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[59]) -- "Player 2 - H1 Win, H2 Loss"
            player2SplitH1BetAmount:SetTextColor(0, 1, 0)
            player2SplitH2BetAmount:SetTextColor(1, 0, 0)
            player2SplitH2Loss()

            if playerFrame.player2SplitHand1CardTotalText:GetText() == "Blackjack" then
                player2SplitH1BJ()
            else
                player2SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player2InsuranceWin()
            else
                player2InsuranceLoss()
            end

            player2SessionWinAnnouncement()

            player2Hotstreak = 0
            player2HotStreakCheck()
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[73]) -- "Player 3 - H1 Win, H2 Loss"
            player3SplitH1BetAmount:SetTextColor(0, 1, 0)
            player3SplitH2BetAmount:SetTextColor(1, 0, 0)
            player3SplitH2Loss()

            if playerFrame.player3SplitHand1CardTotalText:GetText() == "Blackjack" then
                player3SplitH1BJ()
            else
                player3SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player3InsuranceWin()
            else
                player3InsuranceLoss()
            end

            player3SessionWinAnnouncement()

            player3Hotstreak = 0
            player3HotStreakCheck()
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[87]) -- "Player 4 - H1 Win, H2 Loss"
            player4SplitH1BetAmount:SetTextColor(0, 1, 0)
            player4SplitH2BetAmount:SetTextColor(1, 0, 0)
            player4SplitH2Loss()

            if playerFrame.player4SplitHand1CardTotalText:GetText() == "Blackjack" then
                player4SplitH1BJ()
            else
                player4SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player4InsuranceWin()
            else
                player4InsuranceLoss()
            end

            player4SessionWinAnnouncement()

            player4Hotstreak = 0
            player4HotStreakCheck()
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[101]) -- "Player 5 - H1 Win, H2 Loss"
            player5SplitH1BetAmount:SetTextColor(0, 1, 0)
            player5SplitH2BetAmount:SetTextColor(1, 0, 0)
            player5SplitH2Loss()

            if playerFrame.player5SplitHand1CardTotalText:GetText() == "Blackjack" then
                player5SplitH1BJ()
            else
                player5SplitH1Win()
            end

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player5InsuranceWin()
            else
                player5InsuranceLoss()
            end

            player5SessionWinAnnouncement()

            player5Hotstreak = 0
            player5HotStreakCheck()
        end

    -- Push/Push (Split Hand)
    elseif string.find(message, "pushes on both Hand 1 and Hand 2") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[47]) -- "Player 1 - H1 Push, H2 Push"
            player1SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player1SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player1SplitH2Push()
            player1SplitH1Push()
            
            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player1InsuranceWin()
            else
                player1InsuranceLoss()
            end

            player1SessionWinAnnouncement()

        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[61]) -- "Player 2 - H1 Push, H2 Push"
            player2SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player2SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player2SplitH2Push()
            player2SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player2InsuranceWin()
            else
                player2InsuranceLoss()
            end

            player2SessionWinAnnouncement()

        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[75]) -- "Player 3 - H1 Push, H2 Push"
            player3SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player3SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player3SplitH2Push()
            player3SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player3InsuranceWin()
            else
                player3InsuranceLoss()
            end

            player3SessionWinAnnouncement()

        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[89]) -- "Player 4 - H1 Push, H2 Push"
            player4SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player4SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player4SplitH2Push()
            player4SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player4InsuranceWin()
            else
                player4InsuranceLoss()
            end

            player4SessionWinAnnouncement()

        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[103]) -- "Player 5 - H1 Push, H2 Push"
            player5SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player5SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player5SplitH2Push()
            player5SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player5InsuranceWin()
            else
                player5InsuranceLoss()
            end

            player5SessionWinAnnouncement()

        end

    -- Push/Win (Split Hand)
    elseif string.find(message, "pushes on Hand 1 and has won Hand 2") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[46]) -- "Player 1 - H1 Push, H2 Win"
            player1SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player1SplitH2BetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                player1SplitH2BJ()
            else
                player1SplitH2Win()
            end

            player1SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player1InsuranceWin()
            else
                player1InsuranceLoss()
            end

            player1SessionWinAnnouncement()

            player1Hotstreak = player1Hotstreak + 1
            player1HotStreakCheck()
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[60]) -- "Player 2 - H1 Push, H2 Win"
            player2SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player2SplitH2BetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                player2SplitH2BJ()
            else
                player2SplitH2Win()
            end

            player2SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player2InsuranceWin()
            else
                player2InsuranceLoss()
            end

            player2SessionWinAnnouncement()

            player2Hotstreak = player2Hotstreak + 1
            player2HotStreakCheck()
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[74]) -- "Player 3 - H1 Push, H2 Win"
            player3SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player3SplitH2BetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                player3SplitH2BJ()
            else
                player3SplitH2Win()
            end

            player3SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player3InsuranceWin()
            else
                player3InsuranceLoss()
            end

            player3SessionWinAnnouncement()

            player3Hotstreak = player3Hotstreak + 1
            player3HotStreakCheck()
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[88]) -- "Player 4 - H1 Push, H2 Win"
            player4SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player4SplitH2BetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                player4SplitH2BJ()
            else
                player4SplitH2Win()
            end

            player4SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player4InsuranceWin()
            else
                player4InsuranceLoss()
            end

            player4SessionWinAnnouncement()

            player4Hotstreak = player4Hotstreak + 1
            player4HotStreakCheck()
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[102]) -- "Player 5 - H1 Push, H2 Win"
            player5SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player5SplitH2BetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                player5SplitH2BJ()
            else
                player5SplitH2Win()
            end

            player5SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player5InsuranceWin()
            else
                player5InsuranceLoss()
            end

            player5SessionWinAnnouncement()

            player5Hotstreak = player5Hotstreak + 1
            player5HotStreakCheck()
        end

    -- Push/Loss (Split Hand)
    elseif string.find(message, "pushes on Hand 1 and has lost Hand 2") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[48]) -- "Player 1 - H1 Push, H2 Loss"
            player1SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player1SplitH2BetAmount:SetTextColor(1, 0, 0)
            player1SplitH2Loss()
            player1SplitH1Push()
            
            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player1InsuranceWin()
            else
                player1InsuranceLoss()
            end

            player1SessionWinAnnouncement()

            player1Hotstreak = 0
            player1HotStreakCheck()
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[62]) -- "Player 2 - H1 Push, H2 Loss"
            player2SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player2SplitH2BetAmount:SetTextColor(1, 0, 0)
            player2SplitH2Loss()
            player2SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player2InsuranceWin()
            else
                player2InsuranceLoss()
            end

            player2SessionWinAnnouncement()

            player2Hotstreak = 0
            player2HotStreakCheck()
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[76]) -- "Player 3 - H1 Push, H2 Loss"
            player3SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player3SplitH2BetAmount:SetTextColor(1, 0, 0)
            player3SplitH2Loss()
            player3SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player3InsuranceWin()
            else
                player3InsuranceLoss()
            end

            player3SessionWinAnnouncement()

            player3Hotstreak = 0
            player3HotStreakCheck()
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[90]) -- "Player 4 - H1 Push, H2 Loss"
            player4SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player4SplitH2BetAmount:SetTextColor(1, 0, 0)
            player4SplitH2Loss()
            player4SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player4InsuranceWin()
            else
                player4InsuranceLoss()
            end

            player4SessionWinAnnouncement()

            player4Hotstreak = 0
            player4HotStreakCheck()
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[104]) -- "Player 5 - H1 Push, H2 Loss"
            player5SplitH1BetAmount:SetTextColor(0.2, 0.7, 1)
            player5SplitH2BetAmount:SetTextColor(1, 0, 0)
            player5SplitH2Loss()
            player5SplitH1Push()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player5InsuranceWin()
            else
                player5InsuranceLoss()
            end

            player5SessionWinAnnouncement()

            player5Hotstreak = 0
            player5HotStreakCheck()
        end
    
    -- Loss/Loss (Split Hand)
    elseif string.find(message, "has lost both Hand 1 and Hand 2") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[51]) -- "Player 1 - H1 Loss, H2 Loss"
            player1SplitH1BetAmount:SetTextColor(1, 0, 0)
            player1SplitH2BetAmount:SetTextColor(1, 0, 0)
            player1SplitH2Loss()
            player1SplitH1Loss()
            
            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player1InsuranceWin()
            else
                player1InsuranceLoss()
            end

            player1SessionWinAnnouncement()

            player1Hotstreak = 0
            player1HotStreakCheck()
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[65]) -- "Player 2 - H1 Loss, H2 Loss"
            player2SplitH1BetAmount:SetTextColor(1, 0, 0)
            player2SplitH2BetAmount:SetTextColor(1, 0, 0)
            player2SplitH2Loss()
            player2SplitH1Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player2InsuranceWin()
            else
                player2InsuranceLoss()
            end

            player2SessionWinAnnouncement()

            player2Hotstreak = 0
            player2HotStreakCheck()
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[79]) -- "Player 3 - H1 Loss, H2 Loss"
            player3SplitH1BetAmount:SetTextColor(1, 0, 0)
            player3SplitH2BetAmount:SetTextColor(1, 0, 0)
            player3SplitH2Loss()
            player3SplitH1Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player3InsuranceWin()
            else
                player3InsuranceLoss()
            end

            player3SessionWinAnnouncement()

            player3Hotstreak = 0
            player3HotStreakCheck()
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[93]) -- "Player 4 - H1 Loss, H2 Loss"
            player4SplitH1BetAmount:SetTextColor(1, 0, 0)
            player4SplitH2BetAmount:SetTextColor(1, 0, 0)
            player4SplitH2Loss()
            player4SplitH1Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player4InsuranceWin()
            else
                player4InsuranceLoss()
            end

            player4SessionWinAnnouncement()

            player4Hotstreak = 0
            player4HotStreakCheck()
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[107]) -- "Player 5 - H1 Loss, H2 Loss"
            player5SplitH1BetAmount:SetTextColor(1, 0, 0)
            player5SplitH2BetAmount:SetTextColor(1, 0, 0)
            player5SplitH2Loss()
            player5SplitH1Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player5InsuranceWin()
            else
                player5InsuranceLoss()
            end

            player5SessionWinAnnouncement()

            player5Hotstreak = 0
            player5HotStreakCheck()
        end

    -- Loss/Push (Split Hand)
    elseif string.find(message, "has lost Hand 1 and pushes on Hand 2") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[50]) -- "Player 1 - H1 Loss, H2 Push"
            player1SplitH1BetAmount:SetTextColor(1, 0, 0)
            player1SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player1SplitH2Push()
            player1SplitH1Loss()
            
            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player1InsuranceWin()
            else
                player1InsuranceLoss()
            end

            player1SessionWinAnnouncement()

            player1Hotstreak = 0
            player1HotStreakCheck()
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[64]) -- "Player 2 - H1 Loss, H2 Push"
            player2SplitH1BetAmount:SetTextColor(1, 0, 0)
            player2SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player2SplitH2Push()
            player2SplitH1Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player2InsuranceWin()
            else
                player2InsuranceLoss()
            end

            player2SessionWinAnnouncement()

            player2Hotstreak = 0
            player2HotStreakCheck()
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[78]) -- "Player 3 - H1 Loss, H2 Push"
            player3SplitH1BetAmount:SetTextColor(1, 0, 0)
            player3SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player3SplitH2Push()
            player3SplitH1Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player3InsuranceWin()
            else
                player3InsuranceLoss()
            end

            player3SessionWinAnnouncement()

            player3Hotstreak = 0
            player3HotStreakCheck()
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[92]) -- "Player 4 - H1 Loss, H2 Push"
            player4SplitH1BetAmount:SetTextColor(1, 0, 0)
            player4SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player4SplitH2Push()
            player4SplitH1Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player4InsuranceWin()
            else
                player4InsuranceLoss()
            end

            player4SessionWinAnnouncement()

            player4Hotstreak = 0
            player4HotStreakCheck()
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[106]) -- "Player 5 - H1 Loss, H2 Push"
            player5SplitH1BetAmount:SetTextColor(1, 0, 0)
            player5SplitH2BetAmount:SetTextColor(0.2, 0.7, 1)
            player5SplitH2Push()
            player5SplitH1Loss()

            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player5InsuranceWin()
            else
                player5InsuranceLoss()
            end

            player5SessionWinAnnouncement()

            player5Hotstreak = 0
            player5HotStreakCheck()
        end

    -- Loss/Win (Split Hand)
    elseif string.find(message, "has lost Hand 1 and won Hand 2") then
        if unitName1 and string.find(message, unitName1) then
            PlaySoundFile(soundFilePaths[49]) -- "Player 1 - H1 Loss, H2 Win"
            player1SplitH1BetAmount:SetTextColor(1, 0, 0)
            player1SplitH2BetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player1SplitHand2CardTotalText:GetText() == "Blackjack" then
                player1SplitH2BJ()
            else
                player1SplitH2Win()
            end

            player1SplitH1Loss()
            
            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player1InsuranceWin()
            else
                player1InsuranceLoss()
            end

            player1SessionWinAnnouncement()

            player1Hotstreak = 0
            player1HotStreakCheck()
        elseif unitName2 and string.find(message, unitName2) then
            PlaySoundFile(soundFilePaths[63]) -- "Player 2 - H1 Loss, H2 Win"
            player2SplitH1BetAmount:SetTextColor(1, 0, 0)
            player2SplitH2BetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player2SplitHand2CardTotalText:GetText() == "Blackjack" then
                player2SplitH2BJ()
            else
                player2SplitH2Win()
            end

            player2SplitH1Loss()
            
            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player2InsuranceWin()
            else
                player2InsuranceLoss()
            end

            player2SessionWinAnnouncement()

            player2Hotstreak = 0
            player2HotStreakCheck()
        elseif unitName3 and string.find(message, unitName3) then
            PlaySoundFile(soundFilePaths[77]) -- "Player 3 - H1 Loss, H2 Win"
            player3SplitH1BetAmount:SetTextColor(1, 0, 0)
            player3SplitH2BetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player3SplitHand2CardTotalText:GetText() == "Blackjack" then
                player3SplitH2BJ()
            else
                player3SplitH2Win()
            end

            player3SplitH1Loss()
            
            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player3InsuranceWin()
            else
                player3InsuranceLoss()
            end

            player3SessionWinAnnouncement()

            player3Hotstreak = 0
            player3HotStreakCheck()
        elseif unitName4 and string.find(message, unitName4) then
            PlaySoundFile(soundFilePaths[91]) -- "Player 4 - H1 Loss, H2 Win"
            player4SplitH1BetAmount:SetTextColor(1, 0, 0)
            player4SplitH2BetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player4SplitHand2CardTotalText:GetText() == "Blackjack" then
                player4SplitH2BJ()
            else
                player4SplitH2Win()
            end

            player4SplitH1Loss()
            
            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player4InsuranceWin()
            else
                player4InsuranceLoss()
            end

            player4SessionWinAnnouncement()

            player4Hotstreak = 0
            player4HotStreakCheck()
        elseif unitName5 and string.find(message, unitName5) then
            PlaySoundFile(soundFilePaths[105]) -- "Player 5 - H1 Loss, H2 Win"
            player5SplitH1BetAmount:SetTextColor(1, 0, 0)
            player5SplitH2BetAmount:SetTextColor(0, 1, 0)
            
            if playerFrame.player5SplitHand2CardTotalText:GetText() == "Blackjack" then
                player5SplitH2BJ()
            else
                player5SplitH2Win()
            end

            player5SplitH1Loss()
            
            if playerFrame.dealerCardTotalText:GetText() == "Blackjack" then
                player5InsuranceWin()
            else
                player5InsuranceLoss()
            end

            player5SessionWinAnnouncement()

            player5Hotstreak = 0
            player5HotStreakCheck()
        end
















    -- >>> SIDE BETS <<<
    -- >>> SIDE BETS <<<
    -- >>> SIDE BETS <<<

    














    elseif string.find(message, "hit a Suited Three of a Kind") then
        if string.find(message, "Player 1") then 

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player1213CardName2 = dealtCards[3]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)


            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[6]
                player1213CardName2 = dealtCards[7]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            end

            if player1213CardFileName1 then
                sideBetWinFrame213.player1213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1213CardFileName1)
            else
                print("Card image filename not found for " .. player1213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player1213CardFileName2 then
                sideBetWinFrame213.player1213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1213CardFileName2)
            else
                print("Card image filename not found for " .. player1213CardName2)
            end

            if playerName == unitName1 then
                player1SuitedThreeOfAKindNotification()
            end

            if string.find(message, "congratulations") then
                player1SuitedThreeOfAKindWin()
            else
                print("")
            end

        elseif string.find(message, "Player 2") then

            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player2213CardName2 = dealtCards[3]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[6]
                player2213CardName2 = dealtCards[8]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            end

            if player2213CardFileName1 then
                sideBetWinFrame213.player2213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2213CardFileName1)
            else
                print("Card image filename not found for " .. player2213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player2213CardFileName2 then
                sideBetWinFrame213.player2213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2213CardFileName2)
            else
                print("Card image filename not found for " .. player2213CardName2)
            end

            if playerName == unitName2 then
                player2SuitedThreeOfAKindNotification()
            end

            if string.find(message, "congratulations") then
                player2SuitedThreeOfAKindWin()
            else
                print("")
            end  
        
        elseif string.find(message, "Player 3") then

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player3213CardName2 = dealtCards[3]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[4]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[4]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[8]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[8]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[6]
                player3213CardName2 = dealtCards[9]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            end

            if player3213CardFileName1 then
                sideBetWinFrame213.player3213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3213CardFileName1)
            else
                print("Card image filename not found for " .. player3213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player3213CardFileName2 then
                sideBetWinFrame213.player3213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3213CardFileName2)
            else
                print("Card image filename not found for " .. player3213CardName2)
            end

            if playerName == unitName3 then
                player3SuitedThreeOfAKindNotification()
            end

            if string.find(message, "congratulations") then
                player3SuitedThreeOfAKindWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 4") then

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player4213CardName2 = dealtCards[3]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player4213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[4]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[9]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[6]
                player4213CardName2 = dealtCards[10]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            end

            if player4213CardFileName1 then
                sideBetWinFrame213.player4213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4213CardFileName1)
            else
                print("Card image filename not found for " .. player4213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player4213CardFileName2 then
                sideBetWinFrame213.player4213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4213CardFileName2)
            else
                print("Card image filename not found for " .. player4213CardName2)
            end

            if playerName == unitName4 then
                player4SuitedThreeOfAKindNotification()
            end

            if string.find(message, "congratulations") then
                player4SuitedThreeOfAKindWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 5") then

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player5213CardName2 = dealtCards[3]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[5]
                dealer213CardName1 = dealtCards[6]
                player5213CardName2 = dealtCards[11]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)
            end

            if player5213CardFileName1 then
                sideBetWinFrame213.player5213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5213CardFileName1)
            else
                print("Card image filename not found for " .. player5213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player5213CardFileName2 then
                sideBetWinFrame213.player5213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5213CardFileName2)
            else
                print("Card image filename not found for " .. player5213CardName2)
            end

            if playerName == unitName5 then
                player5SuitedThreeOfAKindNotification()
            end

            if string.find(message, "congratulations") then
                player5SuitedThreeOfAKindWin()
            else
                print("")
            end  

        end
    elseif string.find(message, "hit a Straight Flush") then
        if string.find(message, "Player 1") then 

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player1213CardName2 = dealtCards[3]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)


            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[6]
                player1213CardName2 = dealtCards[7]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            end

            if player1213CardFileName1 then
                sideBetWinFrame213.player1213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1213CardFileName1)
            else
                print("Card image filename not found for " .. player1213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player1213CardFileName2 then
                sideBetWinFrame213.player1213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1213CardFileName2)
            else
                print("Card image filename not found for " .. player1213CardName2)
            end

            if playerName == unitName1 then
                player1StraightFlushNotification()
            end

            if string.find(message, "congratulations") then
                player1StraightFlushWin()
            else
                print("")
            end

        elseif string.find(message, "Player 2") then

            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player2213CardName2 = dealtCards[3]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[6]
                player2213CardName2 = dealtCards[8]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            end

            if player2213CardFileName1 then
                sideBetWinFrame213.player2213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2213CardFileName1)
            else
                print("Card image filename not found for " .. player2213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player2213CardFileName2 then
                sideBetWinFrame213.player2213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2213CardFileName2)
            else
                print("Card image filename not found for " .. player2213CardName2)
            end

            if playerName == unitName2 then
                player2StraightFlushNotification()
            end

            if string.find(message, "congratulations") then
                player2StraightFlushWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 3") then

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player3213CardName2 = dealtCards[3]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[4]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[4]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[8]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[8]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[6]
                player3213CardName2 = dealtCards[9]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            end

            if player3213CardFileName1 then
                sideBetWinFrame213.player3213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3213CardFileName1)
            else
                print("Card image filename not found for " .. player3213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player3213CardFileName2 then
                sideBetWinFrame213.player3213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3213CardFileName2)
            else
                print("Card image filename not found for " .. player3213CardName2)
            end

            if playerName == unitName3 then
                player3StraightFlushNotification()
            end

            if string.find(message, "congratulations") then
                player3StraightFlushWin()
            else
                print("")
            end

        elseif string.find(message, "Player 4") then

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player4213CardName2 = dealtCards[3]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player4213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[4]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[9]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[6]
                player4213CardName2 = dealtCards[10]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            end

            if player4213CardFileName1 then
                sideBetWinFrame213.player4213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4213CardFileName1)
            else
                print("Card image filename not found for " .. player4213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player4213CardFileName2 then
                sideBetWinFrame213.player4213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4213CardFileName2)
            else
                print("Card image filename not found for " .. player4213CardName2)
            end

            if playerName == unitName4 then
                player4StraightFlushNotification()
            end

            if string.find(message, "congratulations") then
                player4StraightFlushWin()
            else
                print("")
            end

        elseif string.find(message, "Player 5") then

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player5213CardName2 = dealtCards[3]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[5]
                dealer213CardName1 = dealtCards[6]
                player5213CardName2 = dealtCards[11]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)
            end

            if player5213CardFileName1 then
                sideBetWinFrame213.player5213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5213CardFileName1)
            else
                print("Card image filename not found for " .. player5213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player5213CardFileName2 then
                sideBetWinFrame213.player5213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5213CardFileName2)
            else
                print("Card image filename not found for " .. player5213CardName2)
            end

            if playerName == unitName5 then
                player5StraightFlushNotification()
            end

            if string.find(message, "congratulations") then
                player5StraightFlushWin()
            else
                print("")
            end 

        end
    elseif string.find(message, "hit a Flush") then
        if string.find(message, "Player 1") then 

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player1213CardName2 = dealtCards[3]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)


            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[6]
                player1213CardName2 = dealtCards[7]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            end

            if player1213CardFileName1 then
                sideBetWinFrame213.player1213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1213CardFileName1)
            else
                print("Card image filename not found for " .. player1213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player1213CardFileName2 then
                sideBetWinFrame213.player1213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1213CardFileName2)
            else
                print("Card image filename not found for " .. player1213CardName2)
            end

            if playerName == unitName1 then
                player1FlushNotification()
            end

            if string.find(message, "congratulations") then
                player1FlushWin()
            else
                print("")
            end

        elseif string.find(message, "Player 2") then

            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player2213CardName2 = dealtCards[3]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[6]
                player2213CardName2 = dealtCards[8]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            end

            if player2213CardFileName1 then
                sideBetWinFrame213.player2213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2213CardFileName1)
            else
                print("Card image filename not found for " .. player2213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player2213CardFileName2 then
                sideBetWinFrame213.player2213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2213CardFileName2)
            else
                print("Card image filename not found for " .. player2213CardName2)
            end

            if playerName == unitName2 then
                player2FlushNotification()
            end

            if string.find(message, "congratulations") then
                player2FlushWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 3") then

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player3213CardName2 = dealtCards[3]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[4]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[4]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[8]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[8]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[6]
                player3213CardName2 = dealtCards[9]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            end

            if player3213CardFileName1 then
                sideBetWinFrame213.player3213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3213CardFileName1)
            else
                print("Card image filename not found for " .. player3213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player3213CardFileName2 then
                sideBetWinFrame213.player3213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3213CardFileName2)
            else
                print("Card image filename not found for " .. player3213CardName2)
            end

            if playerName == unitName3 then
                player3FlushNotification()
            end

            if string.find(message, "congratulations") then
                player3FlushWin()
            else
                print("")
            end

        elseif string.find(message, "Player 4") then

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player4213CardName2 = dealtCards[3]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player4213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[4]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[9]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[6]
                player4213CardName2 = dealtCards[10]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            end

            if player4213CardFileName1 then
                sideBetWinFrame213.player4213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4213CardFileName1)
            else
                print("Card image filename not found for " .. player4213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player4213CardFileName2 then
                sideBetWinFrame213.player4213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4213CardFileName2)
            else
                print("Card image filename not found for " .. player4213CardName2)
            end

            if playerName == unitName4 then
                player4FlushNotification()
            end

            if string.find(message, "congratulations") then
                player4FlushWin()
            else
                print("")
            end

        elseif string.find(message, "Player 5") then

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player5213CardName2 = dealtCards[3]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[5]
                dealer213CardName1 = dealtCards[6]
                player5213CardName2 = dealtCards[11]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)
            end

            if player5213CardFileName1 then
                sideBetWinFrame213.player5213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5213CardFileName1)
            else
                print("Card image filename not found for " .. player5213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player5213CardFileName2 then
                sideBetWinFrame213.player5213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5213CardFileName2)
            else
                print("Card image filename not found for " .. player5213CardName2)
            end

            if playerName == unitName5 then
                player5FlushNotification()
            end

            if string.find(message, "congratulations") then
                player5FlushWin()
            else
                print("")
            end 
        end
    elseif string.find(message, "hit a Three of a Kind") then
        if string.find(message, "Player 1") then 

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player1213CardName2 = dealtCards[3]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)


            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[6]
                player1213CardName2 = dealtCards[7]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            end

            if player1213CardFileName1 then
                sideBetWinFrame213.player1213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1213CardFileName1)
            else
                print("Card image filename not found for " .. player1213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player1213CardFileName2 then
                sideBetWinFrame213.player1213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1213CardFileName2)
            else
                print("Card image filename not found for " .. player1213CardName2)
            end

            if playerName == unitName1 then
                player1ThreeOfAKindNotification()
            end

            if string.find(message, "congratulations") then
                player1ThreeOfAKindWin()
            else
                print("")
            end

        elseif string.find(message, "Player 2") then

            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player2213CardName2 = dealtCards[3]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[6]
                player2213CardName2 = dealtCards[8]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            end

            if player2213CardFileName1 then
                sideBetWinFrame213.player2213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2213CardFileName1)
            else
                print("Card image filename not found for " .. player2213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player2213CardFileName2 then
                sideBetWinFrame213.player2213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2213CardFileName2)
            else
                print("Card image filename not found for " .. player2213CardName2)
            end

            if playerName == unitName2 then
                player2ThreeOfAKindNotification()
            end

            if string.find(message, "congratulations") then
                player2ThreeOfAKindWin()
            else
                print("")
            end  
        
        elseif string.find(message, "Player 3") then

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player3213CardName2 = dealtCards[3]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[4]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[4]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[8]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[8]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[6]
                player3213CardName2 = dealtCards[9]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            end

            if player3213CardFileName1 then
                sideBetWinFrame213.player3213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3213CardFileName1)
            else
                print("Card image filename not found for " .. player3213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player3213CardFileName2 then
                sideBetWinFrame213.player3213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3213CardFileName2)
            else
                print("Card image filename not found for " .. player3213CardName2)
            end

            if playerName == unitName3 then
                player3ThreeOfAKindNotification()
            end

            if string.find(message, "congratulations") then
                player3ThreeOfAKindWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 4") then

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player4213CardName2 = dealtCards[3]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player4213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[4]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[9]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[6]
                player4213CardName2 = dealtCards[10]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            end

            if player4213CardFileName1 then
                sideBetWinFrame213.player4213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4213CardFileName1)
            else
                print("Card image filename not found for " .. player4213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player4213CardFileName2 then
                sideBetWinFrame213.player4213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4213CardFileName2)
            else
                print("Card image filename not found for " .. player4213CardName2)
            end

            if playerName == unitName4 then
                player4ThreeOfAKindNotification()
            end

            if string.find(message, "congratulations") then
                player4ThreeOfAKindWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 5") then

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player5213CardName2 = dealtCards[3]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[5]
                dealer213CardName1 = dealtCards[6]
                player5213CardName2 = dealtCards[11]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)
            end

            if player5213CardFileName1 then
                sideBetWinFrame213.player5213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5213CardFileName1)
            else
                print("Card image filename not found for " .. player5213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player5213CardFileName2 then
                sideBetWinFrame213.player5213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5213CardFileName2)
            else
                print("Card image filename not found for " .. player5213CardName2)
            end

            if playerName == unitName5 then
                player5ThreeOfAKindNotification()
            end

            if string.find(message, "congratulations") then
                player5ThreeOfAKindWin()
            else
                print("")
            end

        end
    elseif string.find(message, "hit a Straight") then
        if string.find(message, "Player 1") then 

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player1213CardName2 = dealtCards[3]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player1213CardName2 = dealtCards[4]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)


            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player1213CardName2 = dealtCards[5]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player1213CardName2 = dealtCards[6]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player1213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[6]
                player1213CardName2 = dealtCards[7]

                player1213CardFileName1 = GetCardFileName(player1213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player1213CardFileName2 = GetCardFileName(player1213CardName2)

            end

            if player1213CardFileName1 then
                sideBetWinFrame213.player1213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1213CardFileName1)
            else
                print("Card image filename not found for " .. player1213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player1213CardFileName2 then
                sideBetWinFrame213.player1213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1213CardFileName2)
            else
                print("Card image filename not found for " .. player1213CardName2)
            end

            if playerName == unitName1 then
                player1StraightNotification()
            end

            if string.find(message, "congratulations") then
                player1StraightWin()
            else
                print("")
            end
        elseif string.find(message, "Player 2") then

            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player2213CardName2 = dealtCards[3]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player2213CardName2 = dealtCards[4]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player2213CardName2 = dealtCards[5]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[7]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[5]
                player2213CardName2 = dealtCards[6]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[6]
                player2213CardName2 = dealtCards[8]

                player2213CardFileName1 = GetCardFileName(player2213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player2213CardFileName2 = GetCardFileName(player2213CardName2)

            end

            if player2213CardFileName1 then
                sideBetWinFrame213.player2213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2213CardFileName1)
            else
                print("Card image filename not found for " .. player2213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player2213CardFileName2 then
                sideBetWinFrame213.player2213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2213CardFileName2)
            else
                print("Card image filename not found for " .. player2213CardName2)
            end

            if playerName == unitName2 then
                player2StraightNotification()
            end

            if string.find(message, "congratulations") then
                player2StraightWin()
            else
                print("")
            end  
        
        elseif string.find(message, "Player 3") then

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player3213CardName2 = dealtCards[3]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[4]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player3213CardName2 = dealtCards[4]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[6]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[4]
                player3213CardName2 = dealtCards[5]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[8]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[8]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[5]
                player3213CardName2 = dealtCards[7]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[6]
                player3213CardName2 = dealtCards[9]

                player3213CardFileName1 = GetCardFileName(player3213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player3213CardFileName2 = GetCardFileName(player3213CardName2)

            end

            if player3213CardFileName1 then
                sideBetWinFrame213.player3213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3213CardFileName1)
            else
                print("Card image filename not found for " .. player3213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player3213CardFileName2 then
                sideBetWinFrame213.player3213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3213CardFileName2)
            else
                print("Card image filename not found for " .. player3213CardName2)
            end

            if playerName == unitName3 then
                player3StraightNotification()
            end

            if string.find(message, "congratulations") then
                player3StraightWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 4") then

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player4213CardName2 = dealtCards[3]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[5]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player4213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[3]
                player4213CardName2 = dealtCards[4]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[7]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[4]
                player4213CardName2 = dealtCards[6]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[9]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[5]
                player4213CardName2 = dealtCards[8]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[6]
                player4213CardName2 = dealtCards[10]

                player4213CardFileName1 = GetCardFileName(player4213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player4213CardFileName2 = GetCardFileName(player4213CardName2)

            end

            if player4213CardFileName1 then
                sideBetWinFrame213.player4213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4213CardFileName1)
            else
                print("Card image filename not found for " .. player4213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player4213CardFileName2 then
                sideBetWinFrame213.player4213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4213CardFileName2)
            else
                print("Card image filename not found for " .. player4213CardName2)
            end

            if playerName == unitName4 then
                player4StraightNotification()
            end

            if string.find(message, "congratulations") then
                player4StraightWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 5") then

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[1]
                dealer213CardName1 = dealtCards[2]
                player5213CardName2 = dealtCards[3]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player5213CardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5213CardName2 = dealtCards[5]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5213CardName2 = dealtCards[7]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5213CardName2 = dealtCards[9]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5213CardName1 = dealtCards[5]
                dealer213CardName1 = dealtCards[6]
                player5213CardName2 = dealtCards[11]

                player5213CardFileName1 = GetCardFileName(player5213CardName1)
                dealer213CardFileName1 = GetCardFileName(dealer213CardName1)
                player5213CardFileName2 = GetCardFileName(player5213CardName2)
            end

            if player5213CardFileName1 then
                sideBetWinFrame213.player5213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5213CardFileName1)
            else
                print("Card image filename not found for " .. player5213CardName1)
            end
            if dealer213CardFileName1 then
                sideBetWinFrame213.dealer213CardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. dealer213CardFileName1)
            else
                print("Card image filename not found for " .. dealer213CardName1)
            end
            if player5213CardFileName2 then
                sideBetWinFrame213.player5213CardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5213CardFileName2)
            else
                print("Card image filename not found for " .. player5213CardName2)
            end

            if playerName == unitName5 then
                player5StraightNotification()
            end

            if string.find(message, "congratulations") then
                player5StraightWin()
            else
                print("")
            end

        end
    elseif string.find(message, "hit a Perfect Pair") then
        if string.find(message, "Player 1") then 

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[3]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)


            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[7]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            end

            if player1PPCardFileName1 then
                sideBetWinFramePP.player1PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1PPCardFileName1)
            else
                print("Card image filename not found for " .. player1PPCardName1)
            end
            if player1PPCardFileName2 then
                sideBetWinFramePP.player1PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1PPCardFileName2)
            else
                print("Card image filename not found for " .. player1PPCardName2)
            end

            if playerName == unitName1 then
                player1PerfectPairNotification()
            end

            if string.find(message, "congratulations") then
                player1PerfectPairWin()
            else
                print("")
            end

        elseif string.find(message, "Player 2") then

            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[3]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[4]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[4]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[4]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[7]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[7]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[7]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[8]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            end

            if player2PPCardFileName1 then
                sideBetWinFramePP.player2PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2PPCardFileName1)
            else
                print("Card image filename not found for " .. player2PPCardName1)
            end
            if player2PPCardFileName2 then
                sideBetWinFramePP.player2PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2PPCardFileName2)
            else
                print("Card image filename not found for " .. player2PPCardName2)
            end

            if playerName == unitName2 then
                player2PerfectPairNotification()
            end

            if string.find(message, "congratulations") then
                player2PerfectPairWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 3") then

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[3]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[5]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[5]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[4]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[4]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[7]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[5]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[8]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[8]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[7]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[7]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[9]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            end

            if player3PPCardFileName1 then
                sideBetWinFramePP.player3PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3PPCardFileName1)
            else
                print("Card image filename not found for " .. player3PPCardName1)
            end
            if player3PPCardFileName2 then
                sideBetWinFramePP.player3PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3PPCardFileName2)
            else
                print("Card image filename not found for " .. player3PPCardName2)
            end

            if playerName == unitName3 then
                player3PerfectPairNotification()
            end

            if string.find(message, "congratulations") then
                player3PerfectPairWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 4") then

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[1]
                player4PPCardName2 = dealtCards[3]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[5]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[5]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[5]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player4PPCardName1 = dealtCards[1]
                player4PPCardName2 = dealtCards[4]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[7]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[7]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[6]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[7]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[6]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[6]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[4]
                player4PPCardName2 = dealtCards[9]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[8]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[8]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[8]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[4]
                player4PPCardName2 = dealtCards[10]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            end

            if player4PPCardFileName1 then
                sideBetWinFramePP.player4PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4PPCardFileName1)
            else
                print("Card image filename not found for " .. player4PPCardName1)
            end
            if player4PPCardFileName2 then
                sideBetWinFramePP.player4PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4PPCardFileName2)
            else
                print("Card image filename not found for " .. player4PPCardName2)
            end

            if playerName == unitName4 then
                player4PerfectPairNotification()
            end

            if string.find(message, "congratulations") then
                player4PerfectPairWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 5") then

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[1]
                player5PPCardName2 = dealtCards[3]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[5]
                dealer213CardName1 = dealtCards[6]
                player5PPCardName2 = dealtCards[11]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)
            end

            if player5PPCardFileName1 then
                sideBetWinFramePP.player5PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5PPCardFileName1)
            else
                print("Card image filename not found for " .. player5PPCardName1)
            end
            if player5PPCardFileName2 then
                sideBetWinFramePP.player5PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5PPCardFileName2)
            else
                print("Card image filename not found for " .. player5PPCardName2)
            end

            if playerName == unitName5 then
                player5PerfectPairNotification()
            end

            if string.find(message, "congratulations") then
                player5PerfectPairWin()
            else
                print("")
            end

        end
    elseif string.find(message, "hit a Coloured Pair") then
        if string.find(message, "Player 1") then 

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[3]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)


            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[7]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            end

            if player1PPCardFileName1 then
                sideBetWinFramePP.player1PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1PPCardFileName1)
            else
                print("Card image filename not found for " .. player1PPCardName1)
            end
            if player1PPCardFileName2 then
                sideBetWinFramePP.player1PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1PPCardFileName2)
            else
                print("Card image filename not found for " .. player1PPCardName2)
            end

            if playerName == unitName1 then
                player1ColouredPairNotification()
            end

            if string.find(message, "congratulations") then
                player1ColouredPairWin()
            else
                print("")
            end

        elseif string.find(message, "Player 2") then

            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[3]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[4]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[4]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[4]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[7]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[7]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[7]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[8]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            end

            if player2PPCardFileName1 then
                sideBetWinFramePP.player2PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2PPCardFileName1)
            else
                print("Card image filename not found for " .. player2PPCardName1)
            end
            if player2PPCardFileName2 then
                sideBetWinFramePP.player2PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2PPCardFileName2)
            else
                print("Card image filename not found for " .. player2PPCardName2)
            end

            if playerName == unitName2 then
                player2ColouredPairNotification()
            end

            if string.find(message, "congratulations") then
                player2ColouredPairWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 3") then

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[3]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[5]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[5]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[4]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[4]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[7]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[5]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[8]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[8]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[7]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[7]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[9]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            end

            if player3PPCardFileName1 then
                sideBetWinFramePP.player3PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3PPCardFileName1)
            else
                print("Card image filename not found for " .. player3PPCardName1)
            end
            if player3PPCardFileName2 then
                sideBetWinFramePP.player3PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3PPCardFileName2)
            else
                print("Card image filename not found for " .. player3PPCardName2)
            end

            if playerName == unitName3 then
                player3ColouredPairNotification()
            end

            if string.find(message, "congratulations") then
                player3ColouredPairWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 4") then

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[1]
                player4PPCardName2 = dealtCards[3]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[5]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[5]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[5]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player4PPCardName1 = dealtCards[1]
                player4PPCardName2 = dealtCards[4]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[7]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[7]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[6]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[7]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[6]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[6]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[4]
                player4PPCardName2 = dealtCards[9]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[8]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[8]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[8]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[4]
                player4PPCardName2 = dealtCards[10]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            end

            if player4PPCardFileName1 then
                sideBetWinFramePP.player4PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4PPCardFileName1)
            else
                print("Card image filename not found for " .. player4PPCardName1)
            end
            if player4PPCardFileName2 then
                sideBetWinFramePP.player4PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4PPCardFileName2)
            else
                print("Card image filename not found for " .. player4PPCardName2)
            end

            if playerName == unitName4 then
                player4ColouredPairNotification()
            end

            if string.find(message, "congratulations") then
                player4ColouredPairWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 5") then

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[1]
                player5PPCardName2 = dealtCards[3]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[5]
                dealer213CardName1 = dealtCards[6]
                player5PPCardName2 = dealtCards[11]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)
            end

            if player5PPCardFileName1 then
                sideBetWinFramePP.player5PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5PPCardFileName1)
            else
                print("Card image filename not found for " .. player5PPCardName1)
            end
            if player5PPCardFileName2 then
                sideBetWinFramePP.player5PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5PPCardFileName2)
            else
                print("Card image filename not found for " .. player5PPCardName2)
            end

            if playerName == unitName5 then
                player5ColouredPairNotification()
            end

            if string.find(message, "congratulations") then
                player5ColouredPairWin()
            else
                print("")
            end
            
        end
    elseif string.find(message, "hit a Mixed Pair") then
        if string.find(message, "Player 1") then 

            -- Players: 1
            if player1Active and not player2Active and not player3Active and not player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[3]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[4]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)


            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[5]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[6]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player1PPCardName1 = dealtCards[1]
                player1PPCardName2 = dealtCards[7]

                player1PPCardFileName1 = GetCardFileName(player1PPCardName1)
                player1PPCardFileName2 = GetCardFileName(player1PPCardName2)

            end

            if player1PPCardFileName1 then
                sideBetWinFramePP.player1PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1PPCardFileName1)
            else
                print("Card image filename not found for " .. player1PPCardName1)
            end
            if player1PPCardFileName2 then
                sideBetWinFramePP.player1PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player1PPCardFileName2)
            else
                print("Card image filename not found for " .. player1PPCardName2)
            end

            if playerName == unitName1 then
                player1MixedPairNotification()
            end

            if string.find(message, "congratulations") then
                player1MixedPairWin()
            else
                print("")
            end

        elseif string.find(message, "Player 2") then

            -- Players: 2
            if not player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[3]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2
            elseif player1Active and player2Active and not player3Active and not player4Active and not player5Active then
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[4]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[4]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[4]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)
                
            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[5]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[7]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[7]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[7]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[1]
                player2PPCardName2 = dealtCards[6]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player2PPCardName1 = dealtCards[2]
                player2PPCardName2 = dealtCards[8]

                player2PPCardFileName1 = GetCardFileName(player2PPCardName1)
                player2PPCardFileName2 = GetCardFileName(player2PPCardName2)

            end

            if player2PPCardFileName1 then
                sideBetWinFramePP.player2PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2PPCardFileName1)
            else
                print("Card image filename not found for " .. player2PPCardName1)
            end
            if player2PPCardFileName2 then
                sideBetWinFramePP.player2PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player2PPCardFileName2)
            else
                print("Card image filename not found for " .. player2PPCardName2)
            end

            if playerName == unitName2 then
                player2MixedPairNotification()
            end

            if string.find(message, "congratulations") then
                player2MixedPairWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 3") then

            -- Players: 3
            if not player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[3]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3
            elseif player1Active and not player2Active and player3Active and not player4Active and not player5Active then
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[5]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3
            elseif not player1Active and player2Active and player3Active and not player4Active and not player5Active then
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[5]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[4]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[4]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3
            elseif player1Active and player2Active and player3Active and not player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[7]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[6]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[1]
                player3PPCardName2 = dealtCards[5]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[8]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[8]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[7]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[2]
                player3PPCardName2 = dealtCards[7]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player3PPCardName1 = dealtCards[3]
                player3PPCardName2 = dealtCards[9]

                player3PPCardFileName1 = GetCardFileName(player3PPCardName1)
                player3PPCardFileName2 = GetCardFileName(player3PPCardName2)

            end

            if player3PPCardFileName1 then
                sideBetWinFramePP.player3PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3PPCardFileName1)
            else
                print("Card image filename not found for " .. player3PPCardName1)
            end
            if player3PPCardFileName2 then
                sideBetWinFramePP.player3PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player3PPCardFileName2)
            else
                print("Card image filename not found for " .. player3PPCardName2)
            end

            if playerName == unitName3 then
                player3MixedPairNotification()
            end

            if string.find(message, "congratulations") then
                player3MixedPairWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 4") then

            -- Players: 4
            if not player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[1]
                player4PPCardName2 = dealtCards[3]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 4
            elseif player1Active and not player2Active and not player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[5]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 4
            elseif not player1Active and player2Active and not player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[5]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 3, 4
            elseif not player1Active and not player2Active and player3Active and player4Active and not player5Active then
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[5]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player4PPCardName1 = dealtCards[1]
                player4PPCardName2 = dealtCards[4]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 4
            elseif player1Active and player2Active and not player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[7]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 3, 4
            elseif player1Active and not player2Active and player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[7]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and not player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[6]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 3, 4
            elseif not player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[7]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[6]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[2]
                player4PPCardName2 = dealtCards[6]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 3, 4
            elseif player1Active and player2Active and player3Active and player4Active and not player5Active then    
                player4PPCardName1 = dealtCards[4]
                player4PPCardName2 = dealtCards[9]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[8]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[8]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[3]
                player4PPCardName2 = dealtCards[8]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player4PPCardName1 = dealtCards[4]
                player4PPCardName2 = dealtCards[10]

                player4PPCardFileName1 = GetCardFileName(player4PPCardName1)
                player4PPCardFileName2 = GetCardFileName(player4PPCardName2)

            end

            if player4PPCardFileName1 then
                sideBetWinFramePP.player4PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4PPCardFileName1)
            else
                print("Card image filename not found for " .. player4PPCardName1)
            end
            if player4PPCardFileName2 then
                sideBetWinFramePP.player4PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player4PPCardFileName2)
            else
                print("Card image filename not found for " .. player4PPCardName2)
            end

            if playerName == unitName4 then
                player4MixedPairNotification()
            end

            if string.find(message, "congratulations") then
                player4MixedPairWin()
            else
                print("")
            end  

        elseif string.find(message, "Player 5") then

            -- Players: 5
            if not player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[1]
                player5PPCardName2 = dealtCards[3]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 5
            elseif player1Active and not player2Active and not player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 5
            elseif not player1Active and player2Active and not player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 3, 5
            elseif not player1Active and not player2Active and player3Active and not player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 4, 5
            elseif not player1Active and not player2Active and not player3Active and player4Active and player5Active then
                player5PPCardName1 = dealtCards[2]
                dealer213CardName1 = dealtCards[3]
                player5PPCardName2 = dealtCards[5]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 5
            elseif player1Active and player2Active and not player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 3, 5
            elseif player1Active and not player2Active and player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 4, 5
            elseif player1Active and not player2Active and notPlayer3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 3, 5
            elseif not player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 4, 5
            elseif not player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 3, 4, 5
            elseif not player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[3]
                dealer213CardName1 = dealtCards[4]
                player5PPCardName2 = dealtCards[7]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 3, 5
            elseif player1Active and player2Active and player3Active and not player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 4, 5
            elseif player1Active and player2Active and not player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 3, 4, 5
            elseif player1Active and not player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 2, 3, 4, 5
            elseif not player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[4]
                dealer213CardName1 = dealtCards[5]
                player5PPCardName2 = dealtCards[9]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)

            -- Players: 1, 2, 3, 4, 5
            elseif player1Active and player2Active and player3Active and player4Active and player5Active then    
                player5PPCardName1 = dealtCards[5]
                dealer213CardName1 = dealtCards[6]
                player5PPCardName2 = dealtCards[11]

                player5PPCardFileName1 = GetCardFileName(player5PPCardName1)
                player5PPCardFileName2 = GetCardFileName(player5PPCardName2)
            end

            if player5PPCardFileName1 then
                sideBetWinFramePP.player5PPCardImage1:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5PPCardFileName1)
            else
                print("Card image filename not found for " .. player5PPCardName1)
            end
            if player5PPCardFileName2 then
                sideBetWinFramePP.player5PPCardImage2:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\" .. player5PPCardFileName2)
            else
                print("Card image filename not found for " .. player5PPCardName2)
            end

            if playerName == unitName5 then
                player5MixedPairNotification()
            end

            if string.find(message, "congratulations") then
                player5MixedPairWin()
            else
                print("")
            end
            
        end
    end
    
    AddMessageToScrollFrame(message, sender)
end)

-- Chat event to listen for raid leader chat messages (v.2)
eventFrame = CreateFrame("Frame")
eventFrame:RegisterEvent("CHAT_MSG_RAID_LEADER")
eventFrame:SetScript("OnEvent", function(self, event, message, sender)

    if string.find(message, "{diamond} Mixed Pair:") then
        usingThisToAvoidUpvalues5 = tonumber(string.match(message, "(%d+):"))
        mixedPairPayoutValue = usingThisToAvoidUpvalues5
        mixedPairPayoutReturn = mixedPairPayoutValue + 1
        payoutsFrame.mixedPairPayout:SetText(mixedPairPayoutValue .. ":1")
    elseif string.find(message, "{diamond} Coloured Pair:") then
        usingThisToAvoidUpvalues6 = tonumber(string.match(message, "(%d+):"))
        colouredPairPayoutValue = usingThisToAvoidUpvalues6
        colouredPairPayoutReturn = colouredPairPayoutValue + 1
        payoutsFrame.colouredPairPayout:SetText(colouredPairPayoutValue .. ":1")
    elseif string.find(message, "{diamond} Perfect Pair:") then
        usingThisToAvoidUpvalues7 = tonumber(string.match(message, "(%d+):"))
        perfectPairPayoutValue = usingThisToAvoidUpvalues7
        perfectPairPayoutReturn = perfectPairPayoutValue + 1
        payoutsFrame.perfectPairPayout:SetText(perfectPairPayoutValue .. ":1")
    elseif string.find(message, "{diamond} Flush:") then
        usingThisToAvoidUpvalues8 = tonumber(string.match(message, "(%d+):"))
        flushPayoutValue = usingThisToAvoidUpvalues8
        flushPayoutReturn = flushPayoutValue + 1
        payoutsFrame.flushPayout:SetText(flushPayoutValue .. ":1")
    elseif string.find(message, "{diamond} Straight:") then
        usingThisToAvoidUpvalues9 = tonumber(string.match(message, "(%d+):"))
        straightPayoutValue = usingThisToAvoidUpvalues9
        straightPayoutReturn = straightPayoutValue + 1
        payoutsFrame.straightPayout:SetText(straightPayoutValue .. ":1")
    elseif string.find(message, "{diamond} Three of a Kind:") then
        usingThisToAvoidUpvalues10 = tonumber(string.match(message, "(%d+):"))
        threeOfAKindPayoutValue = usingThisToAvoidUpvalues10
        threeOfAKindPayoutReturn = threeOfAKindPayoutValue + 1
        payoutsFrame.threeOfAKindPayout:SetText(threeOfAKindPayoutValue .. ":1")
    elseif string.find(message, "{diamond} Straight Flush:") then
        usingThisToAvoidUpvalues11 = tonumber(string.match(message, "(%d+):"))
        straightFlushPayoutValue = usingThisToAvoidUpvalues11
        straightFlushPayoutReturn = straightFlushPayoutValue + 1
        payoutsFrame.straightFlushPayout:SetText(straightFlushPayoutValue .. ":1")
    elseif string.find(message, "{diamond} Suited Three of a Kind:") then
        usingThisToAvoidUpvalues12 = tonumber(string.match(message, "(%d+):"))
        suitedThreeOfAKindPayoutValue = usingThisToAvoidUpvalues12
        suitedThreeOfAKindPayoutReturn = suitedThreeOfAKindPayoutValue + 1
        payoutsFrame.suitedThreeOfAKindPayout:SetText(suitedThreeOfAKindPayoutValue .. ":1")
    end
end)

-- Register the event handler for system messages
eventFrame = CreateFrame("Frame")
eventFrame:RegisterEvent("CHAT_MSG_SYSTEM")
eventFrame:SetScript("OnEvent", function(self, event, arg1)
    if event == "CHAT_MSG_SYSTEM" then
        -- Extract sender from the system message
        sender = string.match(arg1, "(%S+) rolls %d+ %(.-%d+%-(%d+)%)")
        if sender then
            AddMessageToScrollFrame(arg1, sender)
        end
    end
end)








-- >> PLAYER 1 <<
-- >> PLAYER 1 <<
-- >> PLAYER 1 <<

playerFrame.takeSeat1Button:SetScript("OnClick", function(self, button, down)
    tableSpectator = false
    SendChatMessage("{circle} " .. playerName .. " has sat down in Seat 1.", "RAID")
    if playerBankingInfo[playerName] then
        bankingInfo = playerBankingInfo[playerName]
        player1totalBetAmount = bankingInfo.totalWagered
        player1totalWin = bankingInfo.totalWon
        player1totalLoss = bankingInfo.totalLost
        player1totalProfit = bankingInfo.totalProfit
        player1TotalBankrollAmount = bankingInfo.bankrollTable
    else
    end
    tipDealerEditBox:Enable()
    playerFrame.tipButton:Enable()
    player1PreloadBetButton:Show()
    player1PreloadEditBoxMainBet:Show()
    player1PreloadEditBoxPPBet:Show()
    player1PreloadEditBox213Bet:Show()
    playerFrame.leaveSeat1Button:Show()
    playerFrame.player1HitButton:Show()
    playerFrame.player1StandButton:Show()
    playerFrame.player1DoubleButton:Show()
    playerFrame.player1SplitButton:Show()
    playerFrame.player1DealNowButton:Show()
    player1ConfirmMainBetButton:Show()
    player1ConfirmPPBetButton:Show()
    player1Confirm213BetButton:Show()
    player1MainBetEditBox:Show()
    player1PPBetEditBox:Show()
    player1213BetEditBox:Show()
    playerFrame.player1MainBetTitle:Show()
    playerFrame.player1PPBetTitle:Show()
    playerFrame.player1213BetTitle:Show()
    --menuFrame.cardsButton:Enable()
    playerFrame.historyButton:Enable()
    menuFrame.preloadButton:Enable()
    playerFrame.cashDeskButton:Enable()
    playerFrame.takeSeat1Button:Hide()
    playerFrame.takeSeat2Button:Disable()
    playerFrame.takeSeat3Button:Disable()
    playerFrame.takeSeat4Button:Disable()
    playerFrame.takeSeat5Button:Disable()
    bankrollFrame.BaseTextDisplay:Hide()
    cashDeskFrame.player1TotalBankroll:Show()
    bankrollFrame.player1TotalBankrollTableDisplay:Show()
    historyFrame.player1totalWageredAmount:Show()
    historyFrame.player1totalWonAmount:Show()
    historyFrame.player1totalLostAmount:Show()
    historyFrame.player1ProfitAmount:Show()


    seatFrame:Show()
    seatFrame.seat1:SetAlpha(1)
    seatFrame.seat1:Show()
    ResetSeatFrame1()
    StartSeat1FadeOut()
    
end)
playerFrame.leaveSeat1Button:SetScript("OnClick", function(self, button, down)
    tableSpectator = true
    SendChatMessage("{circle} " .. playerName .. " has left Seat 1.", "RAID")

    wageredString = historyFrame.player1totalWageredAmount:GetText()
    wonString = historyFrame.player1totalWonAmount:GetText()
    lostString = historyFrame.player1totalLostAmount:GetText()
    profitString = historyFrame.player1ProfitAmount:GetText()
    bankrollString = bankrollFrame.player1TotalBankrollTableDisplay:GetText()

    wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
    wonAmount = tonumber(string.match(wonString, "(%d+)"))
    lostAmount = tonumber(string.match(lostString, "(%d+)"))
    profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
    bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

    -- Store banking information for the leaving player
    if wageredAmount then
        playerBankingInfo[playerName] = {
            totalWagered = wageredAmount,
            totalWon = wonAmount,
            totalLost = lostAmount,
            totalProfit = profitAmount,
            bankrollTable = bankrollAmount,
            bankrollCashDesk = bankrollAmount
        }
    else
        print("wageredAmount == nil")
    end
    tipDealerEditBox:Disable()
    playerFrame.tipButton:Disable()
    player1dealtCardsFrame:Hide()
    player1dealtCardsFrameSplitH1:Hide()
    player1dealtCardsFrameSplitH2:Hide()
    player1PreloadBetButton:Hide()
    player1PreloadEditBoxMainBet:Hide()
    player1PreloadEditBoxPPBet:Hide()
    player1PreloadEditBox213Bet:Hide()
    playerFrame.leaveSeat1Button:Hide()
    playerFrame.player1HitButton:Hide()
    playerFrame.player1StandButton:Hide()
    playerFrame.player1DoubleButton:Hide()
    playerFrame.player1SplitButton:Hide()
    playerFrame.player1DealNowButton:Hide()
    playerFrame.player1InsuranceYesButton:Hide()
    playerFrame.player1InsuranceNoButton:Hide()
    player1ConfirmMainBetButton:Hide()
    player1ConfirmPPBetButton:Hide()
    player1Confirm213BetButton:Hide()
    player1MainBetEditBox:Hide()
    player1PPBetEditBox:Hide()
    player1213BetEditBox:Hide()
    playerFrame.player1MainBetTitle:Hide()
    playerFrame.player1PPBetTitle:Hide()
    playerFrame.player1213BetTitle:Hide()
    playerFrame.player1InsuranceTitle:Hide()
    playerFrame.player1InsuranceSubtitle:Hide()
    menuFrame.cardsButton:Disable()
    playerFrame.historyButton:Disable()
    menuFrame.preloadButton:Disable()
    playerFrame.cashDeskButton:Disable()
    playerFrame.takeSeat1Button:Show()
    if playerFrame.player2Name:GetText() == "Seat Empty" then    
        playerFrame.takeSeat2Button:Enable()
    end
    if playerFrame.player3Name:GetText() == "Seat Empty" then  
        playerFrame.takeSeat3Button:Enable()
    end
    if playerFrame.player4Name:GetText() == "Seat Empty" then 
        playerFrame.takeSeat4Button:Enable()
    end
    if playerFrame.player5Name:GetText() == "Seat Empty" then
        playerFrame.takeSeat5Button:Enable()
    end
    cashDeskFrame.player1TotalBankroll:Hide()
    historyFrame:Hide()
    preloadFrame:Hide()
    historyFrame.player1totalWageredAmount:Hide()
    historyFrame.player1totalWonAmount:Hide()
    historyFrame.player1totalLostAmount:Hide()
    historyFrame.player1ProfitAmount:Hide()
    bankrollFrame.player1TotalBankrollTableDisplay:Hide()
    bankrollFrame.BaseTextDisplay:Show()

    seatFrame:Hide()
    seatFrame.seat1:Hide()
end)
playerFrame.player1InsuranceYesButton:SetScript("OnClick", function()

    player1MainBet = tonumber(player1MainBetEditBox:GetText())
    player1InsuranceValue = player1MainBet / 2
    player1currentBankroll = tonumber(string.match(bankrollFrame.player1TotalBankrollTableDisplay:GetText(), "%d+"))

    if player1currentBankroll - player1InsuranceValue < 0 then
        print("You do not have enough gold in your bankroll to take insurance. Please visit the Cash Desk.")
    else
        player1InsuranceYesIcon:Show()
        playerFrame.player1InsuranceYesButton:Disable()
        playerFrame.player1InsuranceNoButton:Disable()

        if player1MainBet then
            SendChatMessage("[P1] YES to Insurance - adding " .. player1InsuranceValue .. "G", "RAID")         
            playerFrame.player1InsuranceBetAmount:SetText(player1InsuranceValue .. " G")
        end

        if playerBankingInfo[unitName1] then
            bankingInfo = playerBankingInfo[unitName1]
            player1totalBetAmount = bankingInfo.totalWagered + tonumber(player1InsuranceValue)
            bankingInfo.totalWagered = bankingInfo.totalWagered + tonumber(player1InsuranceValue)
            player1TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(player1InsuranceValue)
            bankingInfo.bankrollTable = bankingInfo.bankrollTable - tonumber(player1InsuranceValue)
        else
            player1totalBetAmount = player1totalBetAmount + tonumber(player1InsuranceValue)
            player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(player1InsuranceValue)
        end

        historyFrame.player1totalWageredAmount:SetText(player1totalBetAmount .. " G")
        bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
        cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
    end
end)
playerFrame.player1InsuranceNoButton:SetScript("OnClick", function()
    player1InsuranceNoIcon:Show()
    playerFrame.player1InsuranceYesButton:Disable()
    playerFrame.player1InsuranceNoButton:Disable()
    SendChatMessage("[P1] NO to Insurance", "RAID")
end)
playerFrame.player1HitButton:SetScript("OnClick", function()
    -- Handle the "hit" button action
    SendChatMessage("[P1] Hit", "RAID")
    playerFrame.player1HitButton:Disable()
    playerFrame.player1StandButton:Disable()
    playerFrame.player1DoubleButton:Disable()
    playerFrame.player1SplitButton:Disable()
    if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player1InsuranceYesButton:IsEnabled() and playerFrame.player1InsuranceNoButton:IsEnabled() then
        SendChatMessage("[P1] NO to Insurance", "RAID")
        playerFrame.player1InsuranceYesButton:Disable()
        playerFrame.player1InsuranceNoButton:Disable()
        player1InsuranceNoIcon:Show()
    end
    PlaySoundFile(soundFilePaths[34])
    player1DoubleToggle = true
    timerReset()
end)
playerFrame.player1HitButtonSplitH1:SetScript("OnClick", function()
    SendChatMessage("[P1] (H1) Hit", "RAID")
    playerFrame.player1HitButtonSplitH1:Disable()
    playerFrame.player1StandButtonSplitH1:Disable()
    playerFrame.player1DoubleButtonSplitH1:Disable()
    PlaySoundFile(soundFilePaths[34])
    player1DoubleHand1Toggle = true
    timerReset()
end)
playerFrame.player1HitButtonSplitH2:SetScript("OnClick", function()
    SendChatMessage("[P1] (H2) Hit", "RAID")
    playerFrame.player1HitButtonSplitH2:Disable()
    playerFrame.player1StandButtonSplitH2:Disable()
    playerFrame.player1DoubleButtonSplitH2:Disable()
    PlaySoundFile(soundFilePaths[34])
    player1DoubleHand2Toggle = true
    timerReset()
end)
playerFrame.player1StandButton:SetScript("OnClick", function()
    -- Handle the "stand" button action
    SendChatMessage("[P1] Stand", "RAID")
    playerFrame.player1HitButton:Disable()
    playerFrame.player1StandButton:Disable()
    playerFrame.player1DoubleButton:Disable()
    playerFrame.player1SplitButton:Disable()
    timerFrame.player1TimerText:SetText("")
    timerFrame.player1TimerText:Hide()
    if playerFrame.player1CardTotalText:GetText() == "1 or 11" then
        playerFrame.player1CardTotalText:SetText("11")
    elseif playerFrame.player1CardTotalText:GetText() == "2 or 12" then
        playerFrame.player1CardTotalText:SetText("12")
    elseif playerFrame.player1CardTotalText:GetText() == "3 or 13" then
        playerFrame.player1CardTotalText:SetText("13")
    elseif playerFrame.player1CardTotalText:GetText() == "4 or 14" then
        playerFrame.player1CardTotalText:SetText("14")
    elseif playerFrame.player1CardTotalText:GetText() == "5 or 15" then
        playerFrame.player1CardTotalText:SetText("15")
    elseif playerFrame.player1CardTotalText:GetText() == "6 or 16" then
        playerFrame.player1CardTotalText:SetText("16")
    elseif playerFrame.player1CardTotalText:GetText() == "7 or 17" then
        playerFrame.player1CardTotalText:SetText("17")
    elseif playerFrame.player1CardTotalText:GetText() == "8 or 18" then
        playerFrame.player1CardTotalText:SetText("18")
    elseif playerFrame.player1CardTotalText:GetText() == "9 or 19" then
        playerFrame.player1CardTotalText:SetText("19")
    elseif playerFrame.player1CardTotalText:GetText() == "10 or 20" then
        playerFrame.player1CardTotalText:SetText("20")
    end
    if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player1InsuranceYesButton:IsEnabled() and playerFrame.player1InsuranceNoButton:IsEnabled() then
        SendChatMessage("[P1] NO to Insurance", "RAID")
        playerFrame.player1InsuranceYesButton:Disable()
        playerFrame.player1InsuranceNoButton:Disable()
        player1InsuranceNoIcon:Show()
    end
    PlaySoundFile(soundFilePaths[35])
    player1DoubleToggle = true
    timerReset()
end)
playerFrame.player1StandButtonSplitH1:SetScript("OnClick", function()
    SendChatMessage("[P1] (H1) Stand", "RAID")
    playerFrame.player1HitButtonSplitH1:Disable()
    playerFrame.player1StandButtonSplitH1:Disable()
    playerFrame.player1DoubleButtonSplitH1:Disable()
    PlaySoundFile(soundFilePaths[35])
    player1DoubleHand1Toggle = true
    timerReset()
end)
playerFrame.player1StandButtonSplitH2:SetScript("OnClick", function()
    SendChatMessage("[P1] (H2) Stand", "RAID")
    playerFrame.player1HitButtonSplitH2:Disable()
    playerFrame.player1StandButtonSplitH2:Disable()
    playerFrame.player1DoubleButtonSplitH2:Disable()
    PlaySoundFile(soundFilePaths[35])
    player1DoubleHand2Toggle = true
    timerReset()
end)
playerFrame.player1DoubleButton:SetScript("OnClick", function()

    player1MainBet = tonumber(player1MainBetEditBox:GetText())
    player1currentBankroll = tonumber(string.match(bankrollFrame.player1TotalBankrollTableDisplay:GetText(), "%d+"))

    if player1currentBankroll - player1MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else
        betDoubleAmount1 = 0
        betAmount1 = tonumber(player1MainBetEditBox:GetText()) -- Get the entered bet amount
        if betAmount1 then
            betDoubleAmount1 = betAmount1 * 2
            SendChatMessage("[P1] Double my bet to " ..betDoubleAmount1.. "G", "RAID")
            player1MainBetEditBox:SetText(betDoubleAmount1)
            player1MainBetAmount:SetText(betDoubleAmount1)
            playerFrame.player1HitButton:Disable()
            playerFrame.player1StandButton:Disable()
            playerFrame.player1DoubleButton:Disable()
            playerFrame.player1SplitButton:Disable()
            timerFrame.player1TimerText:SetText("")
            timerFrame.player1TimerText:Hide()
            countdownDuration = 30

            if playerBankingInfo[unitName1] then
                bankingInfo = playerBankingInfo[unitName1]
                player1totalBetAmount = bankingInfo.totalWagered + tonumber(betAmount1)
                bankingInfo.totalWagered = bankingInfo.totalWagered + tonumber(betAmount1)
                player1TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmount1)
                bankingInfo.bankrollTable = bankingInfo.bankrollTable - tonumber(betAmount1)
            else
                player1totalBetAmount = player1totalBetAmount + tonumber(betAmount1)
                player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(betAmount1)
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            historyFrame.player1totalWageredAmount:SetText(player1totalBetAmount .. " G")

        end
        if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player1InsuranceYesButton:IsEnabled() and playerFrame.player1InsuranceNoButton:IsEnabled() then
            SendChatMessage("[P1] NO to Insurance", "RAID")
            playerFrame.player1InsuranceYesButton:Disable()
            playerFrame.player1InsuranceNoButton:Disable()
            player1InsuranceNoIcon:Show()
        end
        PlaySoundFile(soundFilePaths[36])
        player1DoubleToggle = true
        timerReset()

    end
end)
playerFrame.player1DoubleButtonSplitH1:SetScript("OnClick", function()
    PlaySoundFile(soundFilePaths[36])
    player1SplitH1MainBet = tonumber(player1SplitH1EditBox:GetText())
    player1currentBankroll = tonumber(string.match(bankrollFrame.player1TotalBankrollTableDisplay:GetText(), "%d+"))

    if player1currentBankroll - player1SplitH1MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else
    
        betDoubleAmountSplitH1 = 0
        betAmountSplitH1 = tonumber(string.match(player1SplitH1BetAmount:GetText(), "%d+"))
        if betAmountSplitH1 then
            betDoubleAmountSplitH1 = betAmountSplitH1 * 2
            SendChatMessage("[P1] (H1) Double my bet to " ..betDoubleAmountSplitH1.. "G", "RAID")
            player1SplitH1BetAmount:SetText(betDoubleAmountSplitH1 .. " G")
            playerFrame.player1HitButtonSplitH1:Disable()
            playerFrame.player1StandButtonSplitH1:Disable()
            playerFrame.player1DoubleButtonSplitH1:Disable()
            player1DoubleHand1Toggle = true
            timerReset()

            player1SplitH1EditBox:SetText(betDoubleAmountSplitH1)

            if playerBankingInfo[unitName1] then
                bankingInfo = playerBankingInfo[unitName1]
                player1totalBetAmount = bankingInfo.totalWagered + tonumber(betAmountSplitH1)
                bankingInfo.totalWagered = bankingInfo.totalWagered + tonumber(betAmountSplitH1)
                player1TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmountSplitH1)
                bankingInfo.bankrollTable = bankingInfo.bankrollTable - tonumber(betAmountSplitH1)
            else
                player1totalBetAmount = player1totalBetAmount + tonumber(betAmountSplitH1)
                player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(betAmountSplitH1)
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            historyFrame.player1totalWageredAmount:SetText(player1totalBetAmount .. " G")

        end
    end
end)
playerFrame.player1DoubleButtonSplitH2:SetScript("OnClick", function()
    PlaySoundFile(soundFilePaths[36])
    player1SplitH2MainBet = tonumber(player1SplitH2EditBox:GetText())
    player1currentBankroll = tonumber(string.match(bankrollFrame.player1TotalBankrollTableDisplay:GetText(), "%d+"))

    if player1currentBankroll - player1SplitH2MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else

        betDoubleAmountSplitH2 = 0
        betAmountSplitH2 = tonumber(string.match(player1SplitH2BetAmount:GetText(), "%d+"))
        if betAmountSplitH2 then
            betDoubleAmountSplitH2 = betAmountSplitH2 * 2
            SendChatMessage("[P1] (H2) Double my bet to " ..betDoubleAmountSplitH2.. "G", "RAID")
            player1SplitH2BetAmount:SetText(betDoubleAmountSplitH2 .. " G")
            playerFrame.player1HitButtonSplitH2:Disable()
            playerFrame.player1StandButtonSplitH2:Disable()
            playerFrame.player1DoubleButtonSplitH2:Disable()
            player1DoubleHand2Toggle = true
            timerReset()

            player1SplitH2EditBox:SetText(betDoubleAmountSplitH2)

            if playerBankingInfo[unitName1] then
                bankingInfo = playerBankingInfo[unitName1]
                player1totalBetAmount = bankingInfo.totalWagered + tonumber(betAmountSplitH2)
                bankingInfo.totalWagered = bankingInfo.totalWagered + tonumber(betAmountSplitH2)
                player1TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmountSplitH2)
                bankingInfo.bankrollTable = bankingInfo.bankrollTable - tonumber(betAmountSplitH2)
            else
                player1totalBetAmount = player1totalBetAmount + tonumber(betAmountSplitH2)
                player1TotalBankrollAmount = player1TotalBankrollAmount - tonumber(betAmountSplitH2)
            end

            bankrollFrame.player1TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            cashDeskFrame.player1TotalBankroll:SetText("Total Bankroll: " .. player1TotalBankrollAmount .. " G")
            historyFrame.player1totalWageredAmount:SetText(player1totalBetAmount .. " G")

        end
    end
end)
playerFrame.player1SplitButton:SetScript("OnClick", function()
    if playerFrame.player1HitButton:IsEnabled() then
        PlaySoundFile(soundFilePaths[37])
        player1MainBet = tonumber(player1MainBetEditBox:GetText())
        player1currentBankroll = tonumber(string.match(bankrollFrame.player1TotalBankrollTableDisplay:GetText(), "%d+"))

        if player1currentBankroll - player1MainBet < 0 then
            print("You do not have enough gold in your bankroll to split your hand. Please visit the Cash Desk.")
        else

            SendChatMessage("[P1] Split", "RAID")
            playerFrame.player1HitButton:Hide()
            playerFrame.player1StandButton:Hide()
            playerFrame.player1DoubleButton:Hide()
            playerFrame.player1SplitButton:Hide()
            playerFrame.player1InsuranceYesButton:Hide()
            playerFrame.player1InsuranceNoButton:Hide()
            playerFrame.player1InsuranceTitle:Hide()
            playerFrame.player1InsuranceSubtitle:Hide()
            player1ConfirmMainBetButton:Hide()
            player1MainBetEditBox:Hide()
            playerFrame.player1MainBetTitle:Hide()
            

            playerFrame.player1SplitH1Title:Show()
            playerFrame.player1SplitH2Title:Show()
            player1SplitH1EditBox:Show()
            player1SplitH2EditBox:Show()
            playerFrame.player1HitButtonSplitH1:Show()
            playerFrame.player1StandButtonSplitH1:Show()
            playerFrame.player1DoubleButtonSplitH1:Show()
            playerFrame.player1HitButtonSplitH2:Show()
            playerFrame.player1StandButtonSplitH2:Show()
            playerFrame.player1DoubleButtonSplitH2:Show()

            betAmount1 = tonumber(player1MainBetEditBox:GetText())
            if betAmount1 then
                player1SplitH1EditBox:SetText(betAmount1)
                player1SplitH2EditBox:SetText(betAmount1)
            end

            if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player1InsuranceYesButton:IsEnabled() and playerFrame.player1InsuranceNoButton:IsEnabled() then
                SendChatMessage("[P1] NO to Insurance", "RAID")
                playerFrame.player1InsuranceYesButton:Disable()
                playerFrame.player1InsuranceNoButton:Disable()
                player1InsuranceNoIcon:Show()
            end

            timerReset()
        end
    else
        print("You must wait until its your turn.")
    end
end)
playerFrame.player1DealNowButton:SetScript("OnClick", function()
    SendChatMessage("{moon} " .. playerName .. " has indicated they are ready.", "RAID")
    -- Player 1 bet buttons disabled
    player1ConfirmMainBetButton:Disable()
    player1ConfirmPPBetButton:Disable()
    player1Confirm213BetButton:Disable()
    player1PreloadBetButton:Disable()
    playerFrame.player1DealNowButton:Disable()
end)



-- >> PLAYER 2 <<
-- >> PLAYER 2 <<
-- >> PLAYER 2 <<

playerFrame.takeSeat2Button:SetScript("OnClick", function(self, button, down)
    tableSpectator = false
    SendChatMessage("{circle} " .. playerName .. " has sat down in Seat 2.", "RAID")
    if playerBankingInfo[playerName] then
        bankingInfo = playerBankingInfo[playerName]
        player2totalBetAmount = bankingInfo.totalWagered
        player2totalWin = bankingInfo.totalWon
        player2totalLoss = bankingInfo.totalLost
        player2totalProfit = bankingInfo.totalProfit
        player2TotalBankrollAmount = bankingInfo.bankrollTable
    else
    end
    tipDealerEditBox:Enable()
    playerFrame.tipButton:Enable()
    player2PreloadBetButton:Show()
    player2PreloadEditBoxMainBet:Show()
    player2PreloadEditBoxPPBet:Show()
    player2PreloadEditBox213Bet:Show()
    playerFrame.leaveSeat2Button:Show()
    playerFrame.player2HitButton:Show()
    playerFrame.player2StandButton:Show()
    playerFrame.player2DoubleButton:Show()
    playerFrame.player2SplitButton:Show()
    playerFrame.player2DealNowButton:Show()
    player2ConfirmMainBetButton:Show()
    player2ConfirmPPBetButton:Show()
    player2Confirm213BetButton:Show()
    player2MainBetEditBox:Show()
    player2PPBetEditBox:Show()
    player2213BetEditBox:Show()
    playerFrame.player2MainBetTitle:Show()
    playerFrame.player2PPBetTitle:Show()
    playerFrame.player2213BetTitle:Show()
    --menuFrame.cardsButton:Enable()
    playerFrame.historyButton:Enable()
    menuFrame.preloadButton:Enable()
    playerFrame.cashDeskButton:Enable()
    playerFrame.takeSeat1Button:Disable()
    playerFrame.takeSeat2Button:Hide()
    playerFrame.takeSeat3Button:Disable()
    playerFrame.takeSeat4Button:Disable()
    playerFrame.takeSeat5Button:Disable()
    bankrollFrame.BaseTextDisplay:Hide()
    cashDeskFrame.player2TotalBankroll:Show()
    bankrollFrame.player2TotalBankrollTableDisplay:Show()
    historyFrame.player2totalWageredAmount:Show()
    historyFrame.player2totalWonAmount:Show()
    historyFrame.player2totalLostAmount:Show()
    historyFrame.player2ProfitAmount:Show()
    seatFrame:Show()
    seatFrame.seat2:SetAlpha(1)
    seatFrame.seat2:Show()
    ResetSeatFrame2()
    StartSeat2FadeOut()
end)
playerFrame.leaveSeat2Button:SetScript("OnClick", function(self, button, down)
    tableSpectator = true
    SendChatMessage("{circle} " .. playerName .. " has left Seat 2.", "RAID")

    wageredString = historyFrame.player2totalWageredAmount:GetText()
    wonString = historyFrame.player2totalWonAmount:GetText()
    lostString = historyFrame.player2totalLostAmount:GetText()
    profitString = historyFrame.player2ProfitAmount:GetText()
    bankrollString = bankrollFrame.player2TotalBankrollTableDisplay:GetText()

    wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
    wonAmount = tonumber(string.match(wonString, "(%d+)"))
    lostAmount = tonumber(string.match(lostString, "(%d+)"))
    profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
    bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

    -- Store banking information for the leaving player
    if wageredAmount then
        playerBankingInfo[playerName] = {
            totalWagered = wageredAmount,
            totalWon = wonAmount,
            totalLost = lostAmount,
            totalProfit = profitAmount,
            bankrollTable = bankrollAmount,
            bankrollCashDesk = bankrollAmount
        }
    else
        print("wageredAmount == nil")
    end
    tipDealerEditBox:Disable()
    playerFrame.tipButton:Disable()
    player2dealtCardsFrame:Hide()
    player2dealtCardsFrameSplitH1:Hide()
    player2dealtCardsFrameSplitH2:Hide()
    player2PreloadBetButton:Hide()
    player2PreloadEditBoxMainBet:Hide()
    player2PreloadEditBoxPPBet:Hide()
    player2PreloadEditBox213Bet:Hide()
    playerFrame.leaveSeat2Button:Hide()
    playerFrame.player2HitButton:Hide()
    playerFrame.player2StandButton:Hide()
    playerFrame.player2DoubleButton:Hide()
    playerFrame.player2SplitButton:Hide()
    playerFrame.player2DealNowButton:Hide()
    playerFrame.player2InsuranceYesButton:Hide()
    playerFrame.player2InsuranceNoButton:Hide()
    player2ConfirmMainBetButton:Hide()
    player2ConfirmPPBetButton:Hide()
    player2Confirm213BetButton:Hide()
    player2MainBetEditBox:Hide()
    player2PPBetEditBox:Hide()
    player2213BetEditBox:Hide()
    playerFrame.player2MainBetTitle:Hide()
    playerFrame.player2PPBetTitle:Hide()
    playerFrame.player2213BetTitle:Hide()
    playerFrame.player2InsuranceTitle:Hide()
    playerFrame.player2InsuranceSubtitle:Hide()
    menuFrame.cardsButton:Disable()
    playerFrame.historyButton:Disable()
    menuFrame.preloadButton:Disable()
    playerFrame.cashDeskButton:Disable()
    playerFrame.takeSeat2Button:Show()
    if playerFrame.player1Name:GetText() == "Seat Empty" then    
        playerFrame.takeSeat1Button:Enable()
    end
    if playerFrame.player3Name:GetText() == "Seat Empty" then  
        playerFrame.takeSeat3Button:Enable()
    end
    if playerFrame.player4Name:GetText() == "Seat Empty" then 
        playerFrame.takeSeat4Button:Enable()
    end
    if playerFrame.player5Name:GetText() == "Seat Empty" then
        playerFrame.takeSeat5Button:Enable()
    end
    cashDeskFrame.player2TotalBankroll:Hide()
    historyFrame:Hide()
    preloadFrame:Hide()
    historyFrame.player2totalWageredAmount:Hide()
    historyFrame.player2totalWonAmount:Hide()
    historyFrame.player2totalLostAmount:Hide()
    historyFrame.player2ProfitAmount:Hide()
    bankrollFrame.player2TotalBankrollTableDisplay:Hide()
    bankrollFrame.BaseTextDisplay:Show()
    seatFrame:Hide()
    seatFrame.seat2:Hide()
end)
playerFrame.player2InsuranceYesButton:SetScript("OnClick", function()

    player2MainBet = tonumber(player2MainBetEditBox:GetText())
    player2InsuranceValue = player2MainBet / 2
    player2currentBankroll = tonumber(string.match(bankrollFrame.player2TotalBankrollTableDisplay:GetText(), "%d+"))

    if player2currentBankroll - player2InsuranceValue < 0 then
        print("You do not have enough gold in your bankroll to take insurance. Please visit the Cash Desk.")
    else
        player2InsuranceYesIcon:Show()
        playerFrame.player2InsuranceYesButton:Disable()
        playerFrame.player2InsuranceNoButton:Disable()

        if player2MainBet then
            SendChatMessage("[P2] YES to Insurance - adding " .. player2InsuranceValue .. "G", "RAID")         
            playerFrame.player2InsuranceBetAmount:SetText(player2InsuranceValue .. " G")
        end

        if playerBankingInfo[unitName2] then
            bankingInfo = playerBankingInfo[unitName2]
            player2totalBetAmount = bankingInfo.totalWagered + tonumber(player2InsuranceValue)
            player2TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(player2InsuranceValue)
        else
            player2totalBetAmount = player2totalBetAmount + tonumber(player2InsuranceValue)
            player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(player2InsuranceValue)
        end

        historyFrame.player2totalWageredAmount:SetText(player2totalBetAmount .. " G")
        bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
        cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
    end
end)
playerFrame.player2InsuranceNoButton:SetScript("OnClick", function()
    player2InsuranceNoIcon:Show()
    playerFrame.player2InsuranceYesButton:Disable()
    playerFrame.player2InsuranceNoButton:Disable()
    SendChatMessage("[P2] NO to Insurance", "RAID")
end)
playerFrame.player2HitButton:SetScript("OnClick", function()
    -- Handle the "hit" button action
    SendChatMessage("[P2] Hit", "RAID")
    playerFrame.player2HitButton:Disable()
    playerFrame.player2StandButton:Disable()
    playerFrame.player2DoubleButton:Disable()
    playerFrame.player2SplitButton:Disable()
    if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player2InsuranceYesButton:IsEnabled() and playerFrame.player2InsuranceNoButton:IsEnabled() then
        SendChatMessage("[P2] NO to Insurance", "RAID")
        playerFrame.player2InsuranceYesButton:Disable()
        playerFrame.player2InsuranceNoButton:Disable()
        player2InsuranceNoIcon:Show()
    end
    PlaySoundFile(soundFilePaths[34])
    player2DoubleToggle = true
    timerReset()
end)
playerFrame.player2HitButtonSplitH1:SetScript("OnClick", function()
    SendChatMessage("[P2] (H1) Hit", "RAID")
    playerFrame.player2HitButtonSplitH1:Disable()
    playerFrame.player2StandButtonSplitH1:Disable()
    playerFrame.player2DoubleButtonSplitH1:Disable()
    PlaySoundFile(soundFilePaths[34])
    player2DoubleHand1Toggle = true
    timerReset()
end)
playerFrame.player2HitButtonSplitH2:SetScript("OnClick", function()
    SendChatMessage("[P2] (H2) Hit", "RAID")
    playerFrame.player2HitButtonSplitH2:Disable()
    playerFrame.player2StandButtonSplitH2:Disable()
    playerFrame.player2DoubleButtonSplitH2:Disable()
    PlaySoundFile(soundFilePaths[34])
    player2DoubleHand2Toggle = true
    timerReset()
end)
playerFrame.player2StandButton:SetScript("OnClick", function()
    -- Handle the "stand" button action
    SendChatMessage("[P2] Stand", "RAID")
    playerFrame.player2HitButton:Disable()
    playerFrame.player2StandButton:Disable()
    playerFrame.player2DoubleButton:Disable()
    playerFrame.player2SplitButton:Disable()
    timerFrame.player2TimerText:SetText("")
    timerFrame.player2TimerText:Hide()
    if playerFrame.player2CardTotalText:GetText() == "1 or 11" then
        playerFrame.player2CardTotalText:SetText("11")
    elseif playerFrame.player2CardTotalText:GetText() == "2 or 12" then
        playerFrame.player2CardTotalText:SetText("12")
    elseif playerFrame.player2CardTotalText:GetText() == "3 or 13" then
        playerFrame.player2CardTotalText:SetText("13")
    elseif playerFrame.player2CardTotalText:GetText() == "4 or 14" then
        playerFrame.player2CardTotalText:SetText("14")
    elseif playerFrame.player2CardTotalText:GetText() == "5 or 15" then
        playerFrame.player2CardTotalText:SetText("15")
    elseif playerFrame.player2CardTotalText:GetText() == "6 or 16" then
        playerFrame.player2CardTotalText:SetText("16")
    elseif playerFrame.player2CardTotalText:GetText() == "7 or 17" then
        playerFrame.player2CardTotalText:SetText("17")
    elseif playerFrame.player2CardTotalText:GetText() == "8 or 18" then
        playerFrame.player2CardTotalText:SetText("18")
    elseif playerFrame.player2CardTotalText:GetText() == "9 or 19" then
        playerFrame.player2CardTotalText:SetText("19")
    elseif playerFrame.player2CardTotalText:GetText() == "10 or 20" then
        playerFrame.player2CardTotalText:SetText("20")
    end
    if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player2InsuranceYesButton:IsEnabled() and playerFrame.player2InsuranceNoButton:IsEnabled() then
        SendChatMessage("[P2] NO to Insurance", "RAID")
        playerFrame.player2InsuranceYesButton:Disable()
        playerFrame.player2InsuranceNoButton:Disable()
        player2InsuranceNoIcon:Show()
    end
    PlaySoundFile(soundFilePaths[35])
    player2DoubleToggle = true
    timerReset()
end)
playerFrame.player2StandButtonSplitH1:SetScript("OnClick", function()
    SendChatMessage("[P2] (H1) Stand", "RAID")
    playerFrame.player2HitButtonSplitH1:Disable()
    playerFrame.player2StandButtonSplitH1:Disable()
    playerFrame.player2DoubleButtonSplitH1:Disable()
    PlaySoundFile(soundFilePaths[35])
    player2DoubleHand1Toggle = true
    timerReset()
end)
playerFrame.player2StandButtonSplitH2:SetScript("OnClick", function()
    SendChatMessage("[P2] (H2) Stand", "RAID")
    playerFrame.player2HitButtonSplitH2:Disable()
    playerFrame.player2StandButtonSplitH2:Disable()
    playerFrame.player2DoubleButtonSplitH2:Disable()
    PlaySoundFile(soundFilePaths[35])
    player2DoubleHand2Toggle = true
    timerReset()
end)
playerFrame.player2DoubleButton:SetScript("OnClick", function()

    player2MainBet = tonumber(player2MainBetEditBox:GetText())
    player2currentBankroll = tonumber(string.match(bankrollFrame.player2TotalBankrollTableDisplay:GetText(), "%d+"))

    if player2currentBankroll - player2MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else
        betDoubleAmount2 = 0
        betAmount2 = tonumber(player2MainBetEditBox:GetText()) -- Get the entered bet amount
        if betAmount2 then
            betDoubleAmount2 = betAmount2 * 2
            SendChatMessage("[P2] Double my bet to " ..betDoubleAmount2.. "G", "RAID")
            player2MainBetEditBox:SetText(betDoubleAmount2)
            player2MainBetAmount:SetText(betDoubleAmount2)
            playerFrame.player2HitButton:Disable()
            playerFrame.player2StandButton:Disable()
            playerFrame.player2DoubleButton:Disable() 
            timerFrame.player2TimerText:SetText("")
            timerFrame.player2TimerText:Hide()
            countdownDuration = 30

            if playerBankingInfo[unitName2] then
                bankingInfo = playerBankingInfo[unitName2]
                player2totalBetAmount = bankingInfo.totalWagered + tonumber(betAmount2)
                player2TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmount2)
            else
                player2totalBetAmount = player2totalBetAmount + tonumber(betAmount2)
                player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(betAmount2)
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            historyFrame.player2totalWageredAmount:SetText(player2totalBetAmount .. " G")

        end
        if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player2InsuranceYesButton:IsEnabled() and playerFrame.player2InsuranceNoButton:IsEnabled() then
            SendChatMessage("[P2] NO to Insurance", "RAID")
            playerFrame.player2InsuranceYesButton:Disable()
            playerFrame.player2InsuranceNoButton:Disable()
            player2InsuranceNoIcon:Show()
        end
        PlaySoundFile(soundFilePaths[36])
        player2DoubleToggle = true
        timerReset()

    end
end)
playerFrame.player2DoubleButtonSplitH1:SetScript("OnClick", function()
    
    PlaySoundFile(soundFilePaths[36])
    player2SplitH1MainBet = tonumber(player2SplitH1EditBox:GetText())
    player2currentBankroll = tonumber(string.match(bankrollFrame.player2TotalBankrollTableDisplay:GetText(), "%d+"))

    if player2currentBankroll - player2SplitH1MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else
    
        betDoubleAmountSplitH1 = 0
        betAmountSplitH1 = tonumber(string.match(player2SplitH1BetAmount:GetText(), "%d+"))
        if betAmountSplitH1 then
            betDoubleAmountSplitH1 = betAmountSplitH1 * 2
            SendChatMessage("[P2] (H1) Double my bet to " ..betDoubleAmountSplitH1.. "G", "RAID")
            player2SplitH1BetAmount:SetText(betDoubleAmountSplitH1 .. " G")
            playerFrame.player2HitButtonSplitH1:Disable()
            playerFrame.player2StandButtonSplitH1:Disable()
            playerFrame.player2DoubleButtonSplitH1:Disable()
            player2DoubleHand1Toggle = true
            timerReset()

            player2SplitH1EditBox:SetText(betDoubleAmountSplitH1)

            if playerBankingInfo[unitName2] then
                bankingInfo = playerBankingInfo[unitName2]
                player2totalBetAmount = bankingInfo.totalWagered + tonumber(betAmountSplitH1)
                player2TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmountSplitH1)
            else
                player2totalBetAmount = player2totalBetAmount + tonumber(betAmountSplitH1)
                player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(betAmountSplitH1)
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            historyFrame.player2totalWageredAmount:SetText(player2totalBetAmount .. " G")

        end
    end
end)
playerFrame.player2DoubleButtonSplitH2:SetScript("OnClick", function()
    PlaySoundFile(soundFilePaths[36])
    player2SplitH2MainBet = tonumber(player2SplitH2EditBox:GetText())
    player2currentBankroll = tonumber(string.match(bankrollFrame.player2TotalBankrollTableDisplay:GetText(), "%d+"))

    if player2currentBankroll - player2SplitH2MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else

        betDoubleAmountSplitH2 = 0
        betAmountSplitH2 = tonumber(string.match(player2SplitH2BetAmount:GetText(), "%d+"))
        if betAmountSplitH2 then
            betDoubleAmountSplitH2 = betAmountSplitH2 * 2
            SendChatMessage("[P2] (H2) Double my bet to " ..betDoubleAmountSplitH2.. "G", "RAID")
            player2SplitH2BetAmount:SetText(betDoubleAmountSplitH2 .. " G")
            playerFrame.player2HitButtonSplitH2:Disable()
            playerFrame.player2StandButtonSplitH2:Disable()
            playerFrame.player2DoubleButtonSplitH2:Disable()
            player2DoubleHand2Toggle = true
            timerReset()

            player2SplitH2EditBox:SetText(betDoubleAmountSplitH2)

            if playerBankingInfo[unitName2] then
                bankingInfo = playerBankingInfo[unitName2]
                player2totalBetAmount = bankingInfo.totalWagered + tonumber(betAmountSplitH2)
                bankingInfo.totalWagered = bankingInfo.totalWagered + tonumber(betAmountSplitH2)
                bankingInfo.bankrollTable = bankingInfo.bankrollTable - tonumber(betAmountSplitH2)
                player2TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmountSplitH2)
            else
                player2totalBetAmount = player2totalBetAmount + tonumber(betAmountSplitH2)
                player2TotalBankrollAmount = player2TotalBankrollAmount - tonumber(betAmountSplitH2)
            end

            bankrollFrame.player2TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            cashDeskFrame.player2TotalBankroll:SetText("Total Bankroll: " .. player2TotalBankrollAmount .. " G")
            historyFrame.player2totalWageredAmount:SetText(player2totalBetAmount .. " G")

        end
    end
end)
playerFrame.player2SplitButton:SetScript("OnClick", function()
    if playerFrame.player2HitButton:IsEnabled() then
        PlaySoundFile(soundFilePaths[37])
        player2MainBet = tonumber(player2MainBetEditBox:GetText())
        player2currentBankroll = tonumber(string.match(bankrollFrame.player2TotalBankrollTableDisplay:GetText(), "%d+"))

        if playerFrame.player2HitButton:IsShown() then
            if player2currentBankroll - player2MainBet < 0 then
                print("You do not have enough gold in your bankroll to split your hand. Please visit the Cash Desk.")
            else

                SendChatMessage("[P2] Split", "RAID")
                playerFrame.player2HitButton:Hide()
                playerFrame.player2StandButton:Hide()
                playerFrame.player2DoubleButton:Hide()
                playerFrame.player2SplitButton:Hide()
                playerFrame.player2InsuranceYesButton:Hide()
                playerFrame.player2InsuranceNoButton:Hide()
                playerFrame.player2InsuranceTitle:Hide()
                playerFrame.player2InsuranceSubtitle:Hide()
                player2ConfirmMainBetButton:Hide()
                player2MainBetEditBox:Hide()
                playerFrame.player2MainBetTitle:Hide()
                

                playerFrame.player2SplitH1Title:Show()
                playerFrame.player2SplitH2Title:Show()
                player2SplitH1EditBox:Show()
                player2SplitH2EditBox:Show()
                playerFrame.player2HitButtonSplitH1:Show()
                playerFrame.player2StandButtonSplitH1:Show()
                playerFrame.player2DoubleButtonSplitH1:Show()
                playerFrame.player2HitButtonSplitH2:Show()
                playerFrame.player2StandButtonSplitH2:Show()
                playerFrame.player2DoubleButtonSplitH2:Show()

                betAmount2 = tonumber(player2MainBetEditBox:GetText())
                if betAmount2 then
                    player2SplitH1EditBox:SetText(betAmount2)
                    player2SplitH2EditBox:SetText(betAmount2)
                end

                if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player2InsuranceYesButton:IsEnabled() and playerFrame.player2InsuranceNoButton:IsEnabled() then
                    SendChatMessage("[P2] NO to Insurance", "RAID")
                    playerFrame.player2InsuranceYesButton:Disable()
                    playerFrame.player2InsuranceNoButton:Disable()
                    player2InsuranceNoIcon:Show()
                end

                timerReset()
            end
        else
            print("You must wait until its your turn.")
        end
    else
        print("You must wait until its your turn.")
    end  
end)
playerFrame.player2DealNowButton:SetScript("OnClick", function()
    SendChatMessage("{moon} " .. playerName .. " has indicated they are ready.", "RAID")
    -- Player 2 bet buttons disabled
    player2ConfirmMainBetButton:Disable()
    player2ConfirmPPBetButton:Disable()
    player2Confirm213BetButton:Disable()
    player2PreloadBetButton:Disable()
    playerFrame.player2DealNowButton:Disable()
end)




-- >> PLAYER 3 <<
-- >> PLAYER 3 <<
-- >> PLAYER 3 <<

playerFrame.takeSeat3Button:SetScript("OnClick", function(self, button, down)
    tableSpectator = false
    SendChatMessage("{circle} " .. playerName .. " has sat down in Seat 3.", "RAID")
    if playerBankingInfo[playerName] then
        bankingInfo = playerBankingInfo[playerName]
        player3totalBetAmount = bankingInfo.totalWagered
        player3totalWin = bankingInfo.totalWon
        player3totalLoss = bankingInfo.totalLost
        player3totalProfit = bankingInfo.totalProfit
        player3TotalBankrollAmount = bankingInfo.bankrollTable
    else
    end
    tipDealerEditBox:Enable()
    playerFrame.tipButton:Enable()
    player3PreloadBetButton:Show()
    player3PreloadEditBoxMainBet:Show()
    player3PreloadEditBoxPPBet:Show()
    player3PreloadEditBox213Bet:Show()
    playerFrame.leaveSeat3Button:Show()
    playerFrame.player3HitButton:Show()
    playerFrame.player3StandButton:Show()
    playerFrame.player3DoubleButton:Show()
    playerFrame.player3SplitButton:Show()
    playerFrame.player3DealNowButton:Show()
    player3ConfirmMainBetButton:Show()
    player3ConfirmPPBetButton:Show()
    player3Confirm213BetButton:Show()
    player3MainBetEditBox:Show()
    player3PPBetEditBox:Show()
    player3213BetEditBox:Show()
    playerFrame.player3MainBetTitle:Show()
    playerFrame.player3PPBetTitle:Show()
    playerFrame.player3213BetTitle:Show()
    --menuFrame.cardsButton:Enable()
    playerFrame.historyButton:Enable()
    menuFrame.preloadButton:Enable()
    playerFrame.cashDeskButton:Enable()
    playerFrame.takeSeat1Button:Disable()
    playerFrame.takeSeat2Button:Disable()
    playerFrame.takeSeat3Button:Hide()
    playerFrame.takeSeat4Button:Disable()
    playerFrame.takeSeat5Button:Disable()
    cashDeskFrame.player3TotalBankroll:Show()
    bankrollFrame.player3TotalBankrollTableDisplay:Show()
    bankrollFrame.BaseTextDisplay:Hide()
    historyFrame.player3totalWageredAmount:Show()
    historyFrame.player3totalWonAmount:Show()
    historyFrame.player3totalLostAmount:Show()
    historyFrame.player3ProfitAmount:Show()
    seatFrame:Show()
    seatFrame.seat3:SetAlpha(1)
    seatFrame.seat3:Show()
    ResetSeatFrame3()
    StartSeat3FadeOut()
end)
playerFrame.leaveSeat3Button:SetScript("OnClick", function(self, button, down)
    tableSpectator = true
    SendChatMessage("{circle} " .. playerName .. " has left Seat 3.", "RAID")
    wageredString = historyFrame.player2totalWageredAmount:GetText()
    wonString = historyFrame.player2totalWonAmount:GetText()
    lostString = historyFrame.player2totalLostAmount:GetText()
    profitString = historyFrame.player2ProfitAmount:GetText()
    bankrollString = bankrollFrame.player2TotalBankrollTableDisplay:GetText()

    wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
    wonAmount = tonumber(string.match(wonString, "(%d+)"))
    lostAmount = tonumber(string.match(lostString, "(%d+)"))
    profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
    bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

    -- Store banking information for the leaving player
    if wageredAmount then
        playerBankingInfo[playerName] = {
            totalWagered = wageredAmount,
            totalWon = wonAmount,
            totalLost = lostAmount,
            totalProfit = profitAmount,
            bankrollTable = bankrollAmount,
            bankrollCashDesk = bankrollAmount
        }
    else
        print("wageredAmount == nil")
    end
    tipDealerEditBox:Disable()
    playerFrame.tipButton:Disable()
    player3dealtCardsFrame:Hide()
    player3dealtCardsFrameSplitH1:Hide()
    player3dealtCardsFrameSplitH2:Hide()
    player3PreloadBetButton:Hide()
    player3PreloadEditBoxMainBet:Hide()
    player3PreloadEditBoxPPBet:Hide()
    player3PreloadEditBox213Bet:Hide()
    playerFrame.leaveSeat3Button:Hide()
    playerFrame.player3HitButton:Hide()
    playerFrame.player3StandButton:Hide()
    playerFrame.player3DoubleButton:Hide()
    playerFrame.player3SplitButton:Hide()
    playerFrame.player3DealNowButton:Hide()
    playerFrame.player3InsuranceYesButton:Hide()
    playerFrame.player3InsuranceNoButton:Hide()
    player3ConfirmMainBetButton:Hide()
    player3ConfirmPPBetButton:Hide()
    player3Confirm213BetButton:Hide()
    player3MainBetEditBox:Hide()
    player3PPBetEditBox:Hide()
    player3213BetEditBox:Hide()
    playerFrame.player3MainBetTitle:Hide()
    playerFrame.player3PPBetTitle:Hide()
    playerFrame.player3213BetTitle:Hide()
    playerFrame.player3InsuranceTitle:Hide()
    playerFrame.player3InsuranceSubtitle:Hide()
    menuFrame.cardsButton:Disable()
    playerFrame.historyButton:Disable()
    menuFrame.preloadButton:Disable()
    playerFrame.cashDeskButton:Disable()
    playerFrame.takeSeat3Button:Show()
    if playerFrame.player1Name:GetText() == "Seat Empty" then    
        playerFrame.takeSeat1Button:Enable()
    end
    if playerFrame.player2Name:GetText() == "Seat Empty" then  
        playerFrame.takeSeat2Button:Enable()
    end
    if playerFrame.player4Name:GetText() == "Seat Empty" then 
        playerFrame.takeSeat4Button:Enable()
    end
    if playerFrame.player5Name:GetText() == "Seat Empty" then
        playerFrame.takeSeat5Button:Enable()
    end
    bankrollFrame.player3TotalBankrollTableDisplay:Hide()
    bankrollFrame.BaseTextDisplay:Show()
    cashDeskFrame.player3TotalBankroll:Hide()
    historyFrame:Hide()
    preloadFrame:Hide()
    historyFrame.player3totalWageredAmount:Hide()
    historyFrame.player3totalWonAmount:Hide()
    historyFrame.player3totalLostAmount:Hide()
    historyFrame.player3ProfitAmount:Hide()
    seatFrame:Hide()
    seatFrame.seat3:Hide()
end)
playerFrame.player3InsuranceYesButton:SetScript("OnClick", function()

    player3MainBet = tonumber(player3MainBetEditBox:GetText())
    player3InsuranceValue = player3MainBet / 2
    player3currentBankroll = tonumber(string.match(bankrollFrame.player3TotalBankrollTableDisplay:GetText(), "%d+"))

    if player3currentBankroll - player3InsuranceValue < 0 then
        print("You do not have enough gold in your bankroll to take insurance. Please visit the Cash Desk.")
    else
        player3InsuranceYesIcon:Show()
        playerFrame.player3InsuranceYesButton:Disable()
        playerFrame.player3InsuranceNoButton:Disable()
 

        if player3MainBet then
            SendChatMessage("[P3] YES to Insurance - adding " .. player3InsuranceValue .. "G", "RAID")         
            playerFrame.player3InsuranceBetAmount:SetText(player3InsuranceValue .. " G")
        end

        if playerBankingInfo[unitName3] then
            bankingInfo = playerBankingInfo[unitName3]
            player3totalBetAmount = bankingInfo.totalWagered + tonumber(player3InsuranceValue)
            player3TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(player3InsuranceValue)
        else
            player3totalBetAmount = player3totalBetAmount + tonumber(player3InsuranceValue)
            player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(player3InsuranceValue)
        end

        historyFrame.player3totalWageredAmount:SetText(player3totalBetAmount .. " G")
        bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
        cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
    end
end)
playerFrame.player3InsuranceNoButton:SetScript("OnClick", function()
    player3InsuranceNoIcon:Show()
    playerFrame.player3InsuranceYesButton:Disable()
    playerFrame.player3InsuranceNoButton:Disable()
    SendChatMessage("[P3] NO to Insurance", "RAID")
end)
playerFrame.player3HitButton:SetScript("OnClick", function()
    -- Handle the "hit" button action
    SendChatMessage("[P3] Hit", "RAID")
    playerFrame.player3HitButton:Disable()
    playerFrame.player3StandButton:Disable()
    playerFrame.player3DoubleButton:Disable()
    playerFrame.player3SplitButton:Disable()
    if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player3InsuranceYesButton:IsEnabled() and playerFrame.player3InsuranceNoButton:IsEnabled() then
        SendChatMessage("[P3] NO to Insurance", "RAID")
        playerFrame.player3InsuranceYesButton:Disable()
        playerFrame.player3InsuranceNoButton:Disable()
        player3InsuranceNoIcon:Show()
    end
    PlaySoundFile(soundFilePaths[34])
    player3DoubleToggle = true
    timerReset()
end)
playerFrame.player3HitButtonSplitH1:SetScript("OnClick", function()
    SendChatMessage("[P3] (H1) Hit", "RAID")
    playerFrame.player3HitButtonSplitH1:Disable()
    playerFrame.player3StandButtonSplitH1:Disable()
    playerFrame.player3DoubleButtonSplitH1:Disable()
    PlaySoundFile(soundFilePaths[34])
    player3DoubleHand1Toggle = true
    timerReset()
end)
playerFrame.player3HitButtonSplitH2:SetScript("OnClick", function()
    SendChatMessage("[P3] (H2) Hit", "RAID")
    playerFrame.player3HitButtonSplitH2:Disable()
    playerFrame.player3StandButtonSplitH2:Disable()
    playerFrame.player3DoubleButtonSplitH2:Disable()
    PlaySoundFile(soundFilePaths[34])
    player3DoubleHand2Toggle = true
    timerReset()
end)
playerFrame.player3StandButton:SetScript("OnClick", function()
    -- Handle the "stand" button action
    SendChatMessage("[P3] Stand", "RAID")
    playerFrame.player3HitButton:Disable()
    playerFrame.player3StandButton:Disable()
    playerFrame.player3DoubleButton:Disable()
    playerFrame.player3SplitButton:Disable()
    timerFrame.player3TimerText:SetText("")
    timerFrame.player3TimerText:Hide()
    if playerFrame.player3CardTotalText:GetText() == "1 or 11" then
        playerFrame.player3CardTotalText:SetText("11")
    elseif playerFrame.player3CardTotalText:GetText() == "2 or 12" then
        playerFrame.player3CardTotalText:SetText("12")
    elseif playerFrame.player3CardTotalText:GetText() == "3 or 13" then
        playerFrame.player3CardTotalText:SetText("13")
    elseif playerFrame.player3CardTotalText:GetText() == "4 or 14" then
        playerFrame.player3CardTotalText:SetText("14")
    elseif playerFrame.player3CardTotalText:GetText() == "5 or 15" then
        playerFrame.player3CardTotalText:SetText("15")
    elseif playerFrame.player3CardTotalText:GetText() == "6 or 16" then
        playerFrame.player3CardTotalText:SetText("16")
    elseif playerFrame.player3CardTotalText:GetText() == "7 or 17" then
        playerFrame.player3CardTotalText:SetText("17")
    elseif playerFrame.player3CardTotalText:GetText() == "8 or 18" then
        playerFrame.player3CardTotalText:SetText("18")
    elseif playerFrame.player3CardTotalText:GetText() == "9 or 19" then
        playerFrame.player3CardTotalText:SetText("19")
    elseif playerFrame.player3CardTotalText:GetText() == "10 or 20" then
        playerFrame.player3CardTotalText:SetText("20")
    end
    if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player3InsuranceYesButton:IsEnabled() and playerFrame.player3InsuranceNoButton:IsEnabled() then
        SendChatMessage("[P3] NO to Insurance", "RAID")
        playerFrame.player3InsuranceYesButton:Disable()
        playerFrame.player3InsuranceNoButton:Disable()
        player3InsuranceNoIcon:Show()
    end
    PlaySoundFile(soundFilePaths[35])
    player3DoubleToggle = true
    timerReset()
end)
playerFrame.player3StandButtonSplitH1:SetScript("OnClick", function()
    SendChatMessage("[P3] (H1) Stand", "RAID")
    playerFrame.player3HitButtonSplitH1:Disable()
    playerFrame.player3StandButtonSplitH1:Disable()
    playerFrame.player3DoubleButtonSplitH1:Disable()
    PlaySoundFile(soundFilePaths[35])
    player3DoubleHand1Toggle = true
    timerReset()
end)
playerFrame.player3StandButtonSplitH2:SetScript("OnClick", function()
    SendChatMessage("[P3] (H2) Stand", "RAID")
    playerFrame.player3HitButtonSplitH2:Disable()
    playerFrame.player3StandButtonSplitH2:Disable()
    playerFrame.player3DoubleButtonSplitH2:Disable()
    PlaySoundFile(soundFilePaths[35])
    player3DoubleHand2Toggle = true
    timerReset()
end)
playerFrame.player3DoubleButton:SetScript("OnClick", function()

    player3MainBet = tonumber(player3MainBetEditBox:GetText())
    player3currentBankroll = tonumber(string.match(bankrollFrame.player3TotalBankrollTableDisplay:GetText(), "%d+"))

    if player3currentBankroll - player3MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else
        betDoubleAmount3 = 0
        betAmount3 = tonumber(player3MainBetEditBox:GetText()) -- Get the entered bet amount
        if betAmount3 then
            betDoubleAmount3 = betAmount3 * 2
            SendChatMessage("[P3] Double my bet to " ..betDoubleAmount3.. "G", "RAID")
            player3MainBetEditBox:SetText(betDoubleAmount3)
            player3MainBetAmount:SetText(betDoubleAmount3)
            playerFrame.player3HitButton:Disable()
            playerFrame.player3StandButton:Disable()
            playerFrame.player3DoubleButton:Disable() 
            timerFrame.player3TimerText:SetText("")
            timerFrame.player3TimerText:Hide()
            countdownDuration = 30

            if playerBankingInfo[unitName3] then
                bankingInfo = playerBankingInfo[unitName3]
                player3totalBetAmount = bankingInfo.totalWagered + tonumber(betAmount3)
                player3TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmount3)
            else
                player3totalBetAmount = player3totalBetAmount + tonumber(betAmount3)
                player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(betAmount3)
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            historyFrame.player3totalWageredAmount:SetText(player3totalBetAmount .. " G")

        end
        if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player3InsuranceYesButton:IsEnabled() and playerFrame.player3InsuranceNoButton:IsEnabled() then
            SendChatMessage("[P3] NO to Insurance", "RAID")
            playerFrame.player3InsuranceYesButton:Disable()
            playerFrame.player3InsuranceNoButton:Disable()
            player3InsuranceNoIcon:Show()
        end
        PlaySoundFile(soundFilePaths[36])
        player3DoubleToggle = true
        timerReset()

    end
end)
playerFrame.player3DoubleButtonSplitH1:SetScript("OnClick", function()
    PlaySoundFile(soundFilePaths[36])
    player3SplitH1MainBet = tonumber(player3SplitH1EditBox:GetText())
    player3currentBankroll = tonumber(string.match(bankrollFrame.player3TotalBankrollTableDisplay:GetText(), "%d+"))

    if player3currentBankroll - player3SplitH1MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else
    
        betDoubleAmountSplitH1 = 0
        betAmountSplitH1 = tonumber(string.match(player3SplitH1BetAmount:GetText(), "%d+"))
        if betAmountSplitH1 then
            betDoubleAmountSplitH1 = betAmountSplitH1 * 2
            SendChatMessage("[P3] (H1) Double my bet to " ..betDoubleAmountSplitH1.. "G", "RAID")
            player3SplitH1BetAmount:SetText(betDoubleAmountSplitH1 .. " G")
            playerFrame.player3HitButtonSplitH1:Disable()
            playerFrame.player3StandButtonSplitH1:Disable()
            playerFrame.player3DoubleButtonSplitH1:Disable()
            player3DoubleHand1Toggle = true
            timerReset()

            player3SplitH1EditBox:SetText(betDoubleAmountSplitH1)

            if playerBankingInfo[unitName3] then
                print("betAmountSplitH1 = " .. betAmountSplitH1)
                print("player3TotalBankrollAmount (Before) = " .. player3TotalBankrollAmount)
                bankingInfo = playerBankingInfo[unitName3]
                player3totalBetAmount = bankingInfo.totalWagered + tonumber(betAmountSplitH1)
                player3TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmountSplitH1)
                print("player3TotalBankrollAmount (After) = " .. player3TotalBankrollAmount)
            else
                player3totalBetAmount = player3totalBetAmount + tonumber(betAmountSplitH1)
                player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(betAmountSplitH1)
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            historyFrame.player3totalWageredAmount:SetText(player3totalBetAmount .. " G")

        end
    end
end)
playerFrame.player3DoubleButtonSplitH2:SetScript("OnClick", function()
    PlaySoundFile(soundFilePaths[36])
    player3SplitH2MainBet = tonumber(player3SplitH2EditBox:GetText())
    player3currentBankroll = tonumber(string.match(bankrollFrame.player3TotalBankrollTableDisplay:GetText(), "%d+"))

    if player3currentBankroll - player3SplitH2MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else

        betDoubleAmountSplitH2 = 0
        betAmountSplitH2 = tonumber(string.match(player3SplitH2BetAmount:GetText(), "%d+"))
        if betAmountSplitH2 then
            betDoubleAmountSplitH2 = betAmountSplitH2 * 2
            SendChatMessage("[P3] (H2) Double my bet to " ..betDoubleAmountSplitH2.. "G", "RAID")
            player3SplitH2BetAmount:SetText(betDoubleAmountSplitH2 .. " G")
            playerFrame.player3HitButtonSplitH2:Disable()
            playerFrame.player3StandButtonSplitH2:Disable()
            playerFrame.player3DoubleButtonSplitH2:Disable()
            player3DoubleHand2Toggle = true
            timerReset()

            player3SplitH2EditBox:SetText(betDoubleAmountSplitH2)

            if playerBankingInfo[unitName3] then
                bankingInfo = playerBankingInfo[unitName3]
                player3totalBetAmount = bankingInfo.totalWagered + tonumber(betAmountSplitH2)
                bankingInfo.totalWagered = bankingInfo.totalWagered + tonumber(betAmountSplitH2)
                bankingInfo.bankrollTable = bankingInfo.bankrollTable - tonumber(betAmountSplitH2)
                player3TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmountSplitH2)
            else
                player3totalBetAmount = player3totalBetAmount + tonumber(betAmountSplitH2)
                player3TotalBankrollAmount = player3TotalBankrollAmount - tonumber(betAmountSplitH2)
            end

            bankrollFrame.player3TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            cashDeskFrame.player3TotalBankroll:SetText("Total Bankroll: " .. player3TotalBankrollAmount .. " G")
            historyFrame.player3totalWageredAmount:SetText(player3totalBetAmount .. " G")

        end
    end
end)
playerFrame.player3SplitButton:SetScript("OnClick", function()
    if playerFrame.player3HitButton:IsEnabled() then
        PlaySoundFile(soundFilePaths[37])
        player3MainBet = tonumber(player3MainBetEditBox:GetText())
        player3currentBankroll = tonumber(string.match(bankrollFrame.player3TotalBankrollTableDisplay:GetText(), "%d+"))

        if playerFrame.player3HitButton:IsShown() then
            if player3currentBankroll - player3MainBet < 0 then
                print("You do not have enough gold in your bankroll to split your hand. Please visit the Cash Desk.")
            else

                SendChatMessage("[P3] Split", "RAID")
                playerFrame.player3HitButton:Hide()
                playerFrame.player3StandButton:Hide()
                playerFrame.player3DoubleButton:Hide()
                playerFrame.player3SplitButton:Hide()
                playerFrame.player3InsuranceYesButton:Hide()
                playerFrame.player3InsuranceNoButton:Hide()
                playerFrame.player3InsuranceTitle:Hide()
                playerFrame.player3InsuranceSubtitle:Hide()
                player3ConfirmMainBetButton:Hide()
                player3MainBetEditBox:Hide()
                playerFrame.player3MainBetTitle:Hide()
                

                playerFrame.player3SplitH1Title:Show()
                playerFrame.player3SplitH2Title:Show()
                player3SplitH1EditBox:Show()
                player3SplitH2EditBox:Show()
                playerFrame.player3HitButtonSplitH1:Show()
                playerFrame.player3StandButtonSplitH1:Show()
                playerFrame.player3DoubleButtonSplitH1:Show()
                playerFrame.player3HitButtonSplitH2:Show()
                playerFrame.player3StandButtonSplitH2:Show()
                playerFrame.player3DoubleButtonSplitH2:Show()

                betAmount3 = tonumber(player3MainBetEditBox:GetText())
                if betAmount3 then
                    player3SplitH1EditBox:SetText(betAmount3)
                    player3SplitH2EditBox:SetText(betAmount3)
                end

                if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player3InsuranceYesButton:IsEnabled() and playerFrame.player3InsuranceNoButton:IsEnabled() then
                    SendChatMessage("[P3] NO to Insurance", "RAID")
                    playerFrame.player3InsuranceYesButton:Disable()
                    playerFrame.player3InsuranceNoButton:Disable()
                    player3InsuranceNoIcon:Show()
                end

                timerReset()
            end
        else
            print("You must wait until its your turn.")
        end
    else
        print("You must wait until its your turn.")
    end  
end)
playerFrame.player3DealNowButton:SetScript("OnClick", function()
    SendChatMessage("{moon} " .. playerName .. " has indicated they are ready.", "RAID")
    -- Player 3 bet buttons disabled
    player3ConfirmMainBetButton:Disable()
    player3ConfirmPPBetButton:Disable()
    player3Confirm213BetButton:Disable()
    player3PreloadBetButton:Disable()
    playerFrame.player3DealNowButton:Disable()
end)





-- >> PLAYER 4 <<
-- >> PLAYER 4 <<
-- >> PLAYER 4 <<

playerFrame.takeSeat4Button:SetScript("OnClick", function(self, button, down)
    SendChatMessage("{circle} " .. playerName .. " has sat down in Seat 4.", "RAID")
    tableSpectator = false
    if playerBankingInfo[playerName] then
        bankingInfo = playerBankingInfo[playerName]
        player4totalBetAmount = bankingInfo.totalWagered
        player4totalWin = bankingInfo.totalWon
        player4totalLoss = bankingInfo.totalLost
        player4totalProfit = bankingInfo.totalProfit
        player4TotalBankrollAmount = bankingInfo.bankrollTable
    else
    end
    tipDealerEditBox:Enable()
    playerFrame.tipButton:Enable()
    player4PreloadBetButton:Show()
    player4PreloadEditBoxMainBet:Show()
    player4PreloadEditBoxPPBet:Show()
    player4PreloadEditBox213Bet:Show()
    playerFrame.leaveSeat4Button:Show()
    playerFrame.player4HitButton:Show()
    playerFrame.player4StandButton:Show()
    playerFrame.player4DoubleButton:Show()
    playerFrame.player4SplitButton:Show()
    playerFrame.player4DealNowButton:Show()
    player4ConfirmMainBetButton:Show()
    player4ConfirmPPBetButton:Show()
    player4Confirm213BetButton:Show()
    player4MainBetEditBox:Show()
    player4PPBetEditBox:Show()
    player4213BetEditBox:Show()
    playerFrame.player4MainBetTitle:Show()
    playerFrame.player4PPBetTitle:Show()
    playerFrame.player4213BetTitle:Show()
    --menuFrame.cardsButton:Enable()
    playerFrame.historyButton:Enable()
    menuFrame.preloadButton:Enable()
    playerFrame.cashDeskButton:Enable()
    playerFrame.takeSeat1Button:Disable()
    playerFrame.takeSeat2Button:Disable()
    playerFrame.takeSeat3Button:Disable()
    playerFrame.takeSeat4Button:Hide()
    playerFrame.takeSeat5Button:Disable()
    cashDeskFrame.player4TotalBankroll:Show()
    bankrollFrame.player4TotalBankrollTableDisplay:Show()
    bankrollFrame.BaseTextDisplay:Hide()
    historyFrame.player4totalWageredAmount:Show()
    historyFrame.player4totalWonAmount:Show()
    historyFrame.player4totalLostAmount:Show()
    historyFrame.player4ProfitAmount:Show()
    seatFrame:Show()
    seatFrame.seat4:SetAlpha(1)
    seatFrame.seat4:Show()
    ResetSeatFrame4()
    StartSeat4FadeOut()
end)
playerFrame.leaveSeat4Button:SetScript("OnClick", function(self, button, down)
    tableSpectator = true
    SendChatMessage("{circle} " .. playerName .. " has left Seat 4.", "RAID")
    wageredString = historyFrame.player2totalWageredAmount:GetText()
    wonString = historyFrame.player2totalWonAmount:GetText()
    lostString = historyFrame.player2totalLostAmount:GetText()
    profitString = historyFrame.player2ProfitAmount:GetText()
    bankrollString = bankrollFrame.player2TotalBankrollTableDisplay:GetText()

    wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
    wonAmount = tonumber(string.match(wonString, "(%d+)"))
    lostAmount = tonumber(string.match(lostString, "(%d+)"))
    profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
    bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

    -- Store banking information for the leaving player
    if wageredAmount then
        playerBankingInfo[playerName] = {
            totalWagered = wageredAmount,
            totalWon = wonAmount,
            totalLost = lostAmount,
            totalProfit = profitAmount,
            bankrollTable = bankrollAmount,
            bankrollCashDesk = bankrollAmount
        }
    else
        print("wageredAmount == nil")
    end
    tipDealerEditBox:Disable()
    playerFrame.tipButton:Disable()
    player4dealtCardsFrame:Hide()
    player4dealtCardsFrameSplitH1:Hide()
    player4dealtCardsFrameSplitH2:Hide()
    player4PreloadBetButton:Hide()
    player4PreloadEditBoxMainBet:Hide()
    player4PreloadEditBoxPPBet:Hide()
    player4PreloadEditBox213Bet:Hide()
    playerFrame.leaveSeat4Button:Hide()
    playerFrame.player4HitButton:Hide()
    playerFrame.player4StandButton:Hide()
    playerFrame.player4DoubleButton:Hide()
    playerFrame.player4SplitButton:Hide()
    playerFrame.player4DealNowButton:Hide()
    playerFrame.player4InsuranceYesButton:Hide()
    playerFrame.player4InsuranceNoButton:Hide()
    player4PreloadBetButton:Hide()
    player4ConfirmMainBetButton:Hide()
    player4ConfirmPPBetButton:Hide()
    player4Confirm213BetButton:Hide()
    player4MainBetEditBox:Hide()
    player4PPBetEditBox:Hide()
    player4213BetEditBox:Hide()
    playerFrame.player4MainBetTitle:Hide()
    playerFrame.player4PPBetTitle:Hide()
    playerFrame.player4213BetTitle:Hide()
    playerFrame.player4InsuranceTitle:Hide()
    playerFrame.player4InsuranceSubtitle:Hide()
    menuFrame.cardsButton:Disable()
    playerFrame.historyButton:Disable()
    menuFrame.preloadButton:Disable()
    playerFrame.cashDeskButton:Disable()
    playerFrame.takeSeat4Button:Show()
    if playerFrame.player1Name:GetText() == "Seat Empty" then    
        playerFrame.takeSeat1Button:Enable()
    end
    if playerFrame.player2Name:GetText() == "Seat Empty" then  
        playerFrame.takeSeat2Button:Enable()
    end
    if playerFrame.player3Name:GetText() == "Seat Empty" then 
        playerFrame.takeSeat3Button:Enable()
    end
    if playerFrame.player5Name:GetText() == "Seat Empty" then
        playerFrame.takeSeat5Button:Enable()
    end
    bankrollFrame.player4TotalBankrollTableDisplay:Hide()
    bankrollFrame.BaseTextDisplay:Show()
    cashDeskFrame.player4TotalBankroll:Hide()
    historyFrame:Hide()
    preloadFrame:Hide()
    historyFrame.player4totalWageredAmount:Hide()
    historyFrame.player4totalWonAmount:Hide()
    historyFrame.player4totalLostAmount:Hide()
    historyFrame.player4ProfitAmount:Hide()
    seatFrame:Hide()
    seatFrame.seat4:Hide()
end)
playerFrame.player4InsuranceYesButton:SetScript("OnClick", function()

    player4MainBet = tonumber(player4MainBetEditBox:GetText())
    player4InsuranceValue = player4MainBet / 2
    player4currentBankroll = tonumber(string.match(bankrollFrame.player4TotalBankrollTableDisplay:GetText(), "%d+"))

    if player4currentBankroll - player4InsuranceValue < 0 then
        print("You do not have enough gold in your bankroll to take insurance. Please visit the Cash Desk.")
    else
        player4InsuranceYesIcon:Show()
        playerFrame.player4InsuranceYesButton:Disable()
        playerFrame.player4InsuranceNoButton:Disable()

        if player4MainBet then
            SendChatMessage("[P4] YES to Insurance - adding " .. player4InsuranceValue .. "G", "RAID")         
            playerFrame.player4InsuranceBetAmount:SetText(player4InsuranceValue .. " G")
        end

        if playerBankingInfo[unitName4] then
            bankingInfo = playerBankingInfo[unitName4]
            player4totalBetAmount = bankingInfo.totalWagered + tonumber(player4InsuranceValue)
            player4TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(player4InsuranceValue)
        else
            player4totalBetAmount = player4totalBetAmount + tonumber(player4InsuranceValue)
            player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(player4InsuranceValue)
        end

        historyFrame.player4totalWageredAmount:SetText(player4totalBetAmount .. " G")
        bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
        cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
    end
end)
playerFrame.player4InsuranceNoButton:SetScript("OnClick", function()
    player4InsuranceNoIcon:Show()
    playerFrame.player4InsuranceYesButton:Disable()
    playerFrame.player4InsuranceNoButton:Disable()
    SendChatMessage("[P4] NO to Insurance", "RAID")
end)
playerFrame.player4HitButton:SetScript("OnClick", function()
    -- Handle the "hit" button action
    SendChatMessage("[P4] Hit", "RAID")
    playerFrame.player4HitButton:Disable()
    playerFrame.player4StandButton:Disable()
    playerFrame.player4DoubleButton:Disable()
    playerFrame.player4SplitButton:Disable()
    if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player4InsuranceYesButton:IsEnabled() and playerFrame.player4InsuranceNoButton:IsEnabled() then
        SendChatMessage("[P4] NO to Insurance", "RAID")
        playerFrame.player4InsuranceYesButton:Disable()
        playerFrame.player4InsuranceNoButton:Disable()
        player4InsuranceNoIcon:Show()
    end
    PlaySoundFile(soundFilePaths[34])
    player4DoubleToggle = true
    timerReset()
end)
playerFrame.player4HitButtonSplitH1:SetScript("OnClick", function()
    SendChatMessage("[P4] (H1) Hit", "RAID")
    playerFrame.player4HitButtonSplitH1:Disable()
    playerFrame.player4StandButtonSplitH1:Disable()
    playerFrame.player4DoubleButtonSplitH1:Disable()
    PlaySoundFile(soundFilePaths[34])
    player4DoubleHand1Toggle = true
    timerReset()
end)
playerFrame.player4HitButtonSplitH2:SetScript("OnClick", function()
    SendChatMessage("[P4] (H2) Hit", "RAID")
    playerFrame.player4HitButtonSplitH2:Disable()
    playerFrame.player4StandButtonSplitH2:Disable()
    playerFrame.player4DoubleButtonSplitH2:Disable()
    PlaySoundFile(soundFilePaths[34])
    player4DoubleHand2Toggle = true
    timerReset()
end)
playerFrame.player4StandButton:SetScript("OnClick", function()
    -- Handle the "stand" button action
    SendChatMessage("[P4] Stand", "RAID")
    playerFrame.player4HitButton:Disable()
    playerFrame.player4StandButton:Disable()
    playerFrame.player4DoubleButton:Disable()
    playerFrame.player4SplitButton:Disable()
    timerFrame.player4TimerText:SetText("")
    timerFrame.player4TimerText:Hide()
    if playerFrame.player4CardTotalText:GetText() == "1 or 11" then
        playerFrame.player4CardTotalText:SetText("11")
    elseif playerFrame.player4CardTotalText:GetText() == "2 or 12" then
        playerFrame.player4CardTotalText:SetText("12")
    elseif playerFrame.player4CardTotalText:GetText() == "3 or 13" then
        playerFrame.player4CardTotalText:SetText("13")
    elseif playerFrame.player4CardTotalText:GetText() == "4 or 14" then
        playerFrame.player4CardTotalText:SetText("14")
    elseif playerFrame.player4CardTotalText:GetText() == "5 or 15" then
        playerFrame.player4CardTotalText:SetText("15")
    elseif playerFrame.player4CardTotalText:GetText() == "6 or 16" then
        playerFrame.player4CardTotalText:SetText("16")
    elseif playerFrame.player4CardTotalText:GetText() == "7 or 17" then
        playerFrame.player4CardTotalText:SetText("17")
    elseif playerFrame.player4CardTotalText:GetText() == "8 or 18" then
        playerFrame.player4CardTotalText:SetText("18")
    elseif playerFrame.player4CardTotalText:GetText() == "9 or 19" then
        playerFrame.player4CardTotalText:SetText("19")
    elseif playerFrame.player4CardTotalText:GetText() == "10 or 20" then
        playerFrame.player4CardTotalText:SetText("20")
    end
    if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player4InsuranceYesButton:IsEnabled() and playerFrame.player4InsuranceNoButton:IsEnabled() then
        SendChatMessage("[P4] NO to Insurance", "RAID")
        playerFrame.player4InsuranceYesButton:Disable()
        playerFrame.player4InsuranceNoButton:Disable()
        player4InsuranceNoIcon:Show()
    end
    PlaySoundFile(soundFilePaths[35])
    player4DoubleToggle = true
    timerReset()
end)
playerFrame.player4StandButtonSplitH1:SetScript("OnClick", function()
    SendChatMessage("[P4] (H1) Stand", "RAID")
    playerFrame.player4HitButtonSplitH1:Disable()
    playerFrame.player4StandButtonSplitH1:Disable()
    playerFrame.player4DoubleButtonSplitH1:Disable()
    PlaySoundFile(soundFilePaths[35])
    player4DoubleHand1Toggle = true
    timerReset()
end)
playerFrame.player4StandButtonSplitH2:SetScript("OnClick", function()
    SendChatMessage("[P4] (H2) Stand", "RAID")
    playerFrame.player4HitButtonSplitH2:Disable()
    playerFrame.player4StandButtonSplitH2:Disable()
    playerFrame.player4DoubleButtonSplitH2:Disable()
    PlaySoundFile(soundFilePaths[35])
    player4DoubleHand2Toggle = true
    timerReset()
end)
playerFrame.player4DoubleButton:SetScript("OnClick", function()

    player4MainBet = tonumber(player4MainBetEditBox:GetText())
    player4currentBankroll = tonumber(string.match(bankrollFrame.player4TotalBankrollTableDisplay:GetText(), "%d+"))

    if player4currentBankroll - player4MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else
        betDoubleAmount4 = 0
        betAmount4 = tonumber(player4MainBetEditBox:GetText()) -- Get the entered bet amount
        if betAmount4 then
            betDoubleAmount4 = betAmount4 * 2
            SendChatMessage("[P4] Double my bet to " ..betDoubleAmount4.. "G", "RAID")
            player4MainBetEditBox:SetText(betDoubleAmount4)
            player4MainBetAmount:SetText(betDoubleAmount4)
            playerFrame.player4HitButton:Disable()
            playerFrame.player4StandButton:Disable()
            playerFrame.player4DoubleButton:Disable() 
            timerFrame.player4TimerText:SetText("")
            timerFrame.player4TimerText:Hide()
            countdownDuration = 30

            if playerBankingInfo[unitName4] then
                bankingInfo = playerBankingInfo[unitName4]
                player4totalBetAmount = bankingInfo.totalWagered + tonumber(betAmount4)
                player4TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmount4)
            else
                player4totalBetAmount = player4totalBetAmount + tonumber(betAmount4)
                player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(betAmount4)
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            historyFrame.player4totalWageredAmount:SetText(player4totalBetAmount .. " G")

        end
        if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player4InsuranceYesButton:IsEnabled() and playerFrame.player4InsuranceNoButton:IsEnabled() then
            SendChatMessage("[P4] NO to Insurance", "RAID")
            playerFrame.player4InsuranceYesButton:Disable()
            playerFrame.player4InsuranceNoButton:Disable()
            player4InsuranceNoIcon:Show()
        end
        PlaySoundFile(soundFilePaths[36])
        player4DoubleToggle = true
        timerReset()

    end
end)
playerFrame.player4DoubleButtonSplitH1:SetScript("OnClick", function()
    PlaySoundFile(soundFilePaths[36])
    player4SplitH1MainBet = tonumber(player4SplitH1EditBox:GetText())
    player4currentBankroll = tonumber(string.match(bankrollFrame.player4TotalBankrollTableDisplay:GetText(), "%d+"))

    if player4currentBankroll - player4SplitH1MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else
    
        betDoubleAmountSplitH1 = 0
        betAmountSplitH1 = tonumber(string.match(player4SplitH1BetAmount:GetText(), "%d+"))
        if betAmountSplitH1 then
            betDoubleAmountSplitH1 = betAmountSplitH1 * 2
            SendChatMessage("[P4] (H1) Double my bet to " ..betDoubleAmountSplitH1.. "G", "RAID")
            player4SplitH1BetAmount:SetText(betDoubleAmountSplitH1 .. " G")
            playerFrame.player4HitButtonSplitH1:Disable()
            playerFrame.player4StandButtonSplitH1:Disable()
            playerFrame.player4DoubleButtonSplitH1:Disable()
            player4DoubleHand1Toggle = true
            timerReset()

            player4SplitH1EditBox:SetText(betDoubleAmountSplitH1)

            if playerBankingInfo[unitName4] then
                bankingInfo = playerBankingInfo[unitName4]
                player4totalBetAmount = bankingInfo.totalWagered + tonumber(betAmountSplitH1)
                player4TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmountSplitH1)
            else
                player4totalBetAmount = player4totalBetAmount + tonumber(betAmountSplitH1)
                player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(betAmountSplitH1)
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            historyFrame.player4totalWageredAmount:SetText(player4totalBetAmount .. " G")

        end
    end
end)
playerFrame.player4DoubleButtonSplitH2:SetScript("OnClick", function()
    PlaySoundFile(soundFilePaths[36])
    player4SplitH2MainBet = tonumber(player4SplitH2EditBox:GetText())
    player4currentBankroll = tonumber(string.match(bankrollFrame.player4TotalBankrollTableDisplay:GetText(), "%d+"))

    if player4currentBankroll - player4SplitH2MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else

        betDoubleAmountSplitH2 = 0
        betAmountSplitH2 = tonumber(string.match(player4SplitH2BetAmount:GetText(), "%d+"))
        if betAmountSplitH2 then
            betDoubleAmountSplitH2 = betAmountSplitH2 * 2
            SendChatMessage("[P4] (H2) Double my bet to " ..betDoubleAmountSplitH2.. "G", "RAID")
            player4SplitH2BetAmount:SetText(betDoubleAmountSplitH2 .. " G")
            playerFrame.player4HitButtonSplitH2:Disable()
            playerFrame.player4StandButtonSplitH2:Disable()
            playerFrame.player4DoubleButtonSplitH2:Disable()
            player4DoubleHand2Toggle = true
            timerReset()

            player4SplitH2EditBox:SetText(betDoubleAmountSplitH2)

            if playerBankingInfo[unitName4] then
                bankingInfo = playerBankingInfo[unitName4]
                player4totalBetAmount = bankingInfo.totalWagered + tonumber(betAmountSplitH2)
                bankingInfo.totalWagered = bankingInfo.totalWagered + tonumber(betAmountSplitH2)
                bankingInfo.bankrollTable = bankingInfo.bankrollTable - tonumber(betAmountSplitH2)
                player4TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmountSplitH2)
            else
                player4totalBetAmount = player4totalBetAmount + tonumber(betAmountSplitH2)
                player4TotalBankrollAmount = player4TotalBankrollAmount - tonumber(betAmountSplitH2)
            end

            bankrollFrame.player4TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            cashDeskFrame.player4TotalBankroll:SetText("Total Bankroll: " .. player4TotalBankrollAmount .. " G")
            historyFrame.player4totalWageredAmount:SetText(player4totalBetAmount .. " G")

        end
    end
end)
playerFrame.player4SplitButton:SetScript("OnClick", function()
    if playerFrame.player4HitButton:IsEnabled() then
        PlaySoundFile(soundFilePaths[37])
        player4MainBet = tonumber(player4MainBetEditBox:GetText())
        player4currentBankroll = tonumber(string.match(bankrollFrame.player4TotalBankrollTableDisplay:GetText(), "%d+"))

        if playerFrame.player4HitButton:IsShown() then
            if player4currentBankroll - player4MainBet < 0 then
                print("You do not have enough gold in your bankroll to split your hand. Please visit the Cash Desk.")
            else

                SendChatMessage("[P4] Split", "RAID")
                playerFrame.player4HitButton:Hide()
                playerFrame.player4StandButton:Hide()
                playerFrame.player4DoubleButton:Hide()
                playerFrame.player4SplitButton:Hide()
                playerFrame.player4InsuranceYesButton:Hide()
                playerFrame.player4InsuranceNoButton:Hide()
                playerFrame.player4InsuranceTitle:Hide()
                playerFrame.player4InsuranceSubtitle:Hide()
                player4ConfirmMainBetButton:Hide()
                player4MainBetEditBox:Hide()
                playerFrame.player4MainBetTitle:Hide()
                

                playerFrame.player4SplitH1Title:Show()
                playerFrame.player4SplitH2Title:Show()
                player4SplitH1EditBox:Show()
                player4SplitH2EditBox:Show()
                playerFrame.player4HitButtonSplitH1:Show()
                playerFrame.player4StandButtonSplitH1:Show()
                playerFrame.player4DoubleButtonSplitH1:Show()
                playerFrame.player4HitButtonSplitH2:Show()
                playerFrame.player4StandButtonSplitH2:Show()
                playerFrame.player4DoubleButtonSplitH2:Show()

                betAmount4 = tonumber(player4MainBetEditBox:GetText())
                if betAmount4 then
                    player4SplitH1EditBox:SetText(betAmount4)
                    player4SplitH2EditBox:SetText(betAmount4)
                end

                if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player4InsuranceYesButton:IsEnabled() and playerFrame.player4InsuranceNoButton:IsEnabled() then
                    SendChatMessage("[P4] NO to Insurance", "RAID")
                    playerFrame.player4InsuranceYesButton:Disable()
                    playerFrame.player4InsuranceNoButton:Disable()
                    player4InsuranceNoIcon:Show()
                end

                timerReset()
            end
        else
            print("You must wait until its your turn.")
        end
    else
        print("You must wait until its your turn.")
    end 
end)
playerFrame.player4DealNowButton:SetScript("OnClick", function()
    SendChatMessage("{moon} " .. playerName .. " has indicated they are ready.", "RAID")
    -- Player 4 bet buttons disabled
    player4ConfirmMainBetButton:Disable()
    player4ConfirmPPBetButton:Disable()
    player4Confirm213BetButton:Disable()
    player4PreloadBetButton:Disable()
    playerFrame.player4DealNowButton:Disable()
end)





-- >> PLAYER 5 <<
-- >> PLAYER 5 <<
-- >> PLAYER 5 <<

playerFrame.takeSeat5Button:SetScript("OnClick", function(self, button, down)
    SendChatMessage("{circle} " .. playerName .. " has sat down in Seat 5.", "RAID")
    tableSpectator = false
    if playerBankingInfo[playerName] then
        bankingInfo = playerBankingInfo[playerName]
        player5totalBetAmount = bankingInfo.totalWagered
        player5totalWin = bankingInfo.totalWon
        player5totalLoss = bankingInfo.totalLost
        player5totalProfit = bankingInfo.totalProfit
        player5TotalBankrollAmount = bankingInfo.bankrollTable
    else
    end
    tipDealerEditBox:Enable()
    playerFrame.tipButton:Enable()
    player5PreloadBetButton:Show()
    player5PreloadEditBoxMainBet:Show()
    player5PreloadEditBoxPPBet:Show()
    player5PreloadEditBox213Bet:Show()
    playerFrame.leaveSeat5Button:Show()
    playerFrame.player5HitButton:Show()
    playerFrame.player5StandButton:Show()
    playerFrame.player5DoubleButton:Show()
    playerFrame.player5SplitButton:Show()
    playerFrame.player5DealNowButton:Show()
    player5ConfirmMainBetButton:Show()
    player5ConfirmPPBetButton:Show()
    player5Confirm213BetButton:Show()
    player5MainBetEditBox:Show()
    player5PPBetEditBox:Show()
    player5213BetEditBox:Show()
    playerFrame.player5MainBetTitle:Show()
    playerFrame.player5PPBetTitle:Show()
    playerFrame.player5213BetTitle:Show()
    --menuFrame.cardsButton:Enable()
    playerFrame.historyButton:Enable()
    menuFrame.preloadButton:Enable()
    playerFrame.cashDeskButton:Enable()
    playerFrame.takeSeat1Button:Disable()
    playerFrame.takeSeat2Button:Disable()
    playerFrame.takeSeat3Button:Disable()
    playerFrame.takeSeat4Button:Disable()
    playerFrame.takeSeat5Button:Hide()
    cashDeskFrame.player5TotalBankroll:Show()
    bankrollFrame.player5TotalBankrollTableDisplay:Show()
    bankrollFrame.BaseTextDisplay:Hide()
    historyFrame.player5totalWageredAmount:Show()
    historyFrame.player5totalWonAmount:Show()
    historyFrame.player5totalLostAmount:Show()
    historyFrame.player5ProfitAmount:Show()
    seatFrame:Show()
    seatFrame.seat5:SetAlpha(1)
    seatFrame.seat5:Show()
    ResetSeatFrame5()
    StartSeat5FadeOut()
end)
playerFrame.leaveSeat5Button:SetScript("OnClick", function(self, button, down)
    tableSpectator = true
    SendChatMessage("{circle} " .. playerName .. " has left Seat 5.", "RAID")
    wageredString = historyFrame.player2totalWageredAmount:GetText()
    wonString = historyFrame.player2totalWonAmount:GetText()
    lostString = historyFrame.player2totalLostAmount:GetText()
    profitString = historyFrame.player2ProfitAmount:GetText()
    bankrollString = bankrollFrame.player2TotalBankrollTableDisplay:GetText()

    wageredAmount = tonumber(string.match(wageredString, "(%d+)"))
    wonAmount = tonumber(string.match(wonString, "(%d+)"))
    lostAmount = tonumber(string.match(lostString, "(%d+)"))
    profitAmount = tonumber(string.match(profitString, "(-?%d+)"))
    bankrollAmount = tonumber(string.match(bankrollString, "(%d+)"))

    -- Store banking information for the leaving player
    if wageredAmount then
        playerBankingInfo[playerName] = {
            totalWagered = wageredAmount,
            totalWon = wonAmount,
            totalLost = lostAmount,
            totalProfit = profitAmount,
            bankrollTable = bankrollAmount,
            bankrollCashDesk = bankrollAmount
        }
    else
        print("wageredAmount == nil")
    end
    tipDealerEditBox:Disable()
    playerFrame.tipButton:Disable()
    player5PreloadBetButton:Hide()
    player5PreloadEditBoxMainBet:Hide()
    player5PreloadEditBoxPPBet:Hide()
    player5PreloadEditBox213Bet:Hide()
    playerFrame.leaveSeat5Button:Hide()
    playerFrame.player5HitButton:Hide()
    playerFrame.player5StandButton:Hide()
    playerFrame.player5DoubleButton:Hide()
    playerFrame.player5SplitButton:Hide()
    playerFrame.player5DealNowButton:Hide()
    playerFrame.player5InsuranceYesButton:Hide()
    playerFrame.player5InsuranceNoButton:Hide()
    player5ConfirmMainBetButton:Hide()
    player5ConfirmPPBetButton:Hide()
    player5Confirm213BetButton:Hide()
    player5MainBetEditBox:Hide()
    player5PPBetEditBox:Hide()
    player5213BetEditBox:Hide()
    playerFrame.player5MainBetTitle:Hide()
    playerFrame.player5PPBetTitle:Hide()
    playerFrame.player5213BetTitle:Hide()
    playerFrame.player5InsuranceTitle:Hide()
    playerFrame.player5InsuranceSubtitle:Hide()
    menuFrame.cardsButton:Disable()
    playerFrame.historyButton:Disable()
    menuFrame.preloadButton:Disable()
    playerFrame.cashDeskButton:Disable()
    playerFrame.takeSeat5Button:Show()
    if playerFrame.player1Name:GetText() == "Seat Empty" then    
        playerFrame.takeSeat1Button:Enable()
    end
    if playerFrame.player2Name:GetText() == "Seat Empty" then  
        playerFrame.takeSeat2Button:Enable()
    end
    if playerFrame.player3Name:GetText() == "Seat Empty" then 
        playerFrame.takeSeat3Button:Enable()
    end
    if playerFrame.player4Name:GetText() == "Seat Empty" then
        playerFrame.takeSeat4Button:Enable()
    end
    bankrollFrame.player5TotalBankrollTableDisplay:Hide()
    bankrollFrame.BaseTextDisplay:Show()
    cashDeskFrame.player5TotalBankroll:Hide()
    historyFrame:Hide()
    preloadFrame:Hide()
    player5dealtCardsFrame:Hide()
    player5dealtCardsFrameSplitH1:Hide()
    player5dealtCardsFrameSplitH2:Hide()
    historyFrame.player5totalWageredAmount:Hide()
    historyFrame.player5totalWonAmount:Hide()
    historyFrame.player5totalLostAmount:Hide()
    historyFrame.player5ProfitAmount:Hide()
    seatFrame:Hide()
    seatFrame.seat5:Hide()
end)
playerFrame.player5InsuranceYesButton:SetScript("OnClick", function()

    player5MainBet = tonumber(player5MainBetEditBox:GetText())
    player5InsuranceValue = player5MainBet / 2
    player5currentBankroll = tonumber(string.match(bankrollFrame.player5TotalBankrollTableDisplay:GetText(), "%d+"))

    if player5currentBankroll - player5InsuranceValue < 0 then
        print("You do not have enough gold in your bankroll to take insurance. Please visit the Cash Desk.")
    else
        player5InsuranceYesIcon:Show()
        playerFrame.player5InsuranceYesButton:Disable()
        playerFrame.player5InsuranceNoButton:Disable()

        if player5MainBet then
            SendChatMessage("[P5] YES to Insurance - adding " .. player5InsuranceValue .. "G", "RAID")         
            playerFrame.player5InsuranceBetAmount:SetText(player5InsuranceValue .. " G")
        end

        if playerBankingInfo[unitName5] then
            bankingInfo = playerBankingInfo[unitName5]
            player5totalBetAmount = bankingInfo.totalWagered + tonumber(player5InsuranceValue)
            player5TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(player5InsuranceValue)
        else
            player5totalBetAmount = player5totalBetAmount + tonumber(player5InsuranceValue)
            player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(player5InsuranceValue)
        end

        historyFrame.player5totalWageredAmount:SetText(player5totalBetAmount .. " G")
        bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
        cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
    end
end)
playerFrame.player5InsuranceNoButton:SetScript("OnClick", function()
    player5InsuranceNoIcon:Show()
    playerFrame.player5InsuranceYesButton:Disable()
    playerFrame.player5InsuranceNoButton:Disable()
    SendChatMessage("[P5] NO to Insurance", "RAID")
end)
playerFrame.player5HitButton:SetScript("OnClick", function()
    -- Handle the "hit" button action
    SendChatMessage("[P5] Hit", "RAID")
    playerFrame.player5HitButton:Disable()
    playerFrame.player5StandButton:Disable()
    playerFrame.player5DoubleButton:Disable()
    playerFrame.player5SplitButton:Disable()
    if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player5InsuranceYesButton:IsEnabled() and playerFrame.player5InsuranceNoButton:IsEnabled() then
        SendChatMessage("[P5] NO to Insurance", "RAID")
        playerFrame.player5InsuranceYesButton:Disable()
        playerFrame.player5InsuranceNoButton:Disable()
        player5InsuranceNoIcon:Show()
    end
    PlaySoundFile(soundFilePaths[34])
    player5DoubleToggle = true
    timerReset()
end)
playerFrame.player5HitButtonSplitH1:SetScript("OnClick", function()
    SendChatMessage("[P5] (H1) Hit", "RAID")
    playerFrame.player5HitButtonSplitH1:Disable()
    playerFrame.player5StandButtonSplitH1:Disable()
    playerFrame.player5DoubleButtonSplitH1:Disable()
    PlaySoundFile(soundFilePaths[34])
    player5DoubleHand1Toggle = true
    timerReset()
end)
playerFrame.player5HitButtonSplitH2:SetScript("OnClick", function()
    SendChatMessage("[P5] (H2) Hit", "RAID")
    playerFrame.player5HitButtonSplitH2:Disable()
    playerFrame.player5StandButtonSplitH2:Disable()
    playerFrame.player5DoubleButtonSplitH2:Disable()
    PlaySoundFile(soundFilePaths[34])
    player5DoubleHand2Toggle = true
    timerReset()
end)
playerFrame.player5StandButton:SetScript("OnClick", function()
    -- Handle the "stand" button action
    SendChatMessage("[P5] Stand", "RAID")
    playerFrame.player5HitButton:Disable()
    playerFrame.player5StandButton:Disable()
    playerFrame.player5DoubleButton:Disable()
    playerFrame.player5SplitButton:Disable()
    timerFrame.player5TimerText:SetText("")
    timerFrame.player5TimerText:Hide()
    if playerFrame.player5CardTotalText:GetText() == "1 or 11" then
        playerFrame.player5CardTotalText:SetText("11")
    elseif playerFrame.player5CardTotalText:GetText() == "2 or 12" then
        playerFrame.player5CardTotalText:SetText("12")
    elseif playerFrame.player5CardTotalText:GetText() == "3 or 13" then
        playerFrame.player5CardTotalText:SetText("13")
    elseif playerFrame.player5CardTotalText:GetText() == "4 or 14" then
        playerFrame.player5CardTotalText:SetText("14")
    elseif playerFrame.player5CardTotalText:GetText() == "5 or 15" then
        playerFrame.player5CardTotalText:SetText("15")
    elseif playerFrame.player5CardTotalText:GetText() == "6 or 16" then
        playerFrame.player5CardTotalText:SetText("16")
    elseif playerFrame.player5CardTotalText:GetText() == "7 or 17" then
        playerFrame.player5CardTotalText:SetText("17")
    elseif playerFrame.player5CardTotalText:GetText() == "8 or 18" then
        playerFrame.player5CardTotalText:SetText("18")
    elseif playerFrame.player5CardTotalText:GetText() == "9 or 19" then
        playerFrame.player5CardTotalText:SetText("19")
    elseif playerFrame.player5CardTotalText:GetText() == "10 or 20" then
        playerFrame.player5CardTotalText:SetText("20")
    end
    if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player5InsuranceYesButton:IsEnabled() and playerFrame.player5InsuranceNoButton:IsEnabled() then
        SendChatMessage("[P5] NO to Insurance", "RAID")
        playerFrame.player5InsuranceYesButton:Disable()
        playerFrame.player5InsuranceNoButton:Disable()
        player5InsuranceNoIcon:Show()
    end
    PlaySoundFile(soundFilePaths[35])
    player5DoubleToggle = true
    timerReset()
end)
playerFrame.player5StandButtonSplitH1:SetScript("OnClick", function()
    SendChatMessage("[P5] (H1) Stand", "RAID")
    playerFrame.player5HitButtonSplitH1:Disable()
    playerFrame.player5StandButtonSplitH1:Disable()
    playerFrame.player5DoubleButtonSplitH1:Disable()
    PlaySoundFile(soundFilePaths[35])
    player5DoubleHand1Toggle = true
    timerReset()
end)
playerFrame.player5StandButtonSplitH2:SetScript("OnClick", function()
    SendChatMessage("[P5] (H2) Stand", "RAID")
    playerFrame.player5HitButtonSplitH2:Disable()
    playerFrame.player5StandButtonSplitH2:Disable()
    playerFrame.player5DoubleButtonSplitH2:Disable()
    PlaySoundFile(soundFilePaths[35])
    player5DoubleHand2Toggle = true
    timerReset()
end)
playerFrame.player5DoubleButton:SetScript("OnClick", function()

    player5MainBet = tonumber(player5MainBetEditBox:GetText())
    player5currentBankroll = tonumber(string.match(bankrollFrame.player5TotalBankrollTableDisplay:GetText(), "%d+"))

    if player5currentBankroll - player5MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else
        betDoubleAmount5 = 0
        betAmount5 = tonumber(player5MainBetEditBox:GetText()) -- Get the entered bet amount
        if betAmount5 then
            betDoubleAmount5 = betAmount5 * 2
            SendChatMessage("[P5] Double my bet to " ..betDoubleAmount5.. "G", "RAID")
            player5MainBetEditBox:SetText(betDoubleAmount5)
            player5MainBetAmount:SetText(betDoubleAmount5)
            playerFrame.player5HitButton:Disable()
            playerFrame.player5StandButton:Disable()
            playerFrame.player5DoubleButton:Disable() 
            timerFrame.player5TimerText:SetText("")
            timerFrame.player5TimerText:Hide()
            countdownDuration = 30

            if playerBankingInfo[unitName5] then
                bankingInfo = playerBankingInfo[unitName5]
                player5totalBetAmount = bankingInfo.totalWagered + tonumber(betAmount5)
                player5TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmount5)
            else
                player5totalBetAmount = player5totalBetAmount + tonumber(betAmount5)
                player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(betAmount5)
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            historyFrame.player5totalWageredAmount:SetText(player5totalBetAmount .. " G")

        end
        if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player5InsuranceYesButton:IsEnabled() and playerFrame.player5InsuranceNoButton:IsEnabled() then
            SendChatMessage("[P5] NO to Insurance", "RAID")
            playerFrame.player5InsuranceYesButton:Disable()
            playerFrame.player5InsuranceNoButton:Disable()
            player5InsuranceNoIcon:Show()
        end
        PlaySoundFile(soundFilePaths[36])
        player5DoubleToggle = true
        timerReset()

    end
end)
playerFrame.player5DoubleButtonSplitH1:SetScript("OnClick", function()
    PlaySoundFile(soundFilePaths[36])
    player5SplitH1MainBet = tonumber(player5SplitH1EditBox:GetText())
    player5currentBankroll = tonumber(string.match(bankrollFrame.player5TotalBankrollTableDisplay:GetText(), "%d+"))

    if player5currentBankroll - player5SplitH1MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else
    
        betDoubleAmountSplitH1 = 0
        betAmountSplitH1 = tonumber(string.match(player5SplitH1BetAmount:GetText(), "%d+"))
        if betAmountSplitH1 then
            betDoubleAmountSplitH1 = betAmountSplitH1 * 2
            SendChatMessage("[P5] (H1) Double my bet to " ..betDoubleAmountSplitH1.. "G", "RAID")
            player5SplitH1BetAmount:SetText(betDoubleAmountSplitH1 .. " G")
            playerFrame.player5HitButtonSplitH1:Disable()
            playerFrame.player5StandButtonSplitH1:Disable()
            playerFrame.player5DoubleButtonSplitH1:Disable()
            player5DoubleHand1Toggle = true
            timerReset()

            player5SplitH1EditBox:SetText(betDoubleAmountSplitH1)

            if playerBankingInfo[unitName5] then
                bankingInfo = playerBankingInfo[unitName5]
                player5totalBetAmount = bankingInfo.totalWagered + tonumber(betAmountSplitH1)
                player5TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmountSplitH1)
            else
                player5totalBetAmount = player5totalBetAmount + tonumber(betAmountSplitH1)
                player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(betAmountSplitH1)
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            historyFrame.player5totalWageredAmount:SetText(player5totalBetAmount .. " G")

        end
    end
end)
playerFrame.player5DoubleButtonSplitH2:SetScript("OnClick", function()
    PlaySoundFile(soundFilePaths[36])
    player5SplitH2MainBet = tonumber(player5SplitH2EditBox:GetText())
    player5currentBankroll = tonumber(string.match(bankrollFrame.player5TotalBankrollTableDisplay:GetText(), "%d+"))

    if player5currentBankroll - player5SplitH2MainBet < 0 then
        print("You do not have enough gold in your bankroll to double your bet. Please visit the Cash Desk.")
    else

        betDoubleAmountSplitH2 = 0
        betAmountSplitH2 = tonumber(string.match(player5SplitH2BetAmount:GetText(), "%d+"))
        if betAmountSplitH2 then
            betDoubleAmountSplitH2 = betAmountSplitH2 * 2
            SendChatMessage("[P5] (H2) Double my bet to " ..betDoubleAmountSplitH2.. "G", "RAID")
            player5SplitH2BetAmount:SetText(betDoubleAmountSplitH2 .. " G")
            playerFrame.player5HitButtonSplitH2:Disable()
            playerFrame.player5StandButtonSplitH2:Disable()
            playerFrame.player5DoubleButtonSplitH2:Disable()
            player5DoubleHand2Toggle = true
            timerReset()

            player5SplitH2EditBox:SetText(betDoubleAmountSplitH2)

            if playerBankingInfo[unitName5] then
                bankingInfo = playerBankingInfo[unitName5]
                player5totalBetAmount = bankingInfo.totalWagered + tonumber(betAmountSplitH2)
                bankingInfo.totalWagered = bankingInfo.totalWagered + tonumber(betAmountSplitH2)
                bankingInfo.bankrollTable = bankingInfo.bankrollTable - tonumber(betAmountSplitH2)
                player5TotalBankrollAmount = bankingInfo.bankrollTable - tonumber(betAmountSplitH2)
            else
                player5totalBetAmount = player5totalBetAmount + tonumber(betAmountSplitH2)
                player5TotalBankrollAmount = player5TotalBankrollAmount - tonumber(betAmountSplitH2)
            end

            bankrollFrame.player5TotalBankrollTableDisplay:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            cashDeskFrame.player5TotalBankroll:SetText("Total Bankroll: " .. player5TotalBankrollAmount .. " G")
            historyFrame.player5totalWageredAmount:SetText(player5totalBetAmount .. " G")

        end
    end
end)
playerFrame.player5SplitButton:SetScript("OnClick", function()
    if playerFrame.player5HitButton:IsEnabled() then
        PlaySoundFile(soundFilePaths[37])
        player5MainBet = tonumber(player5MainBetEditBox:GetText())
        player5currentBankroll = tonumber(string.match(bankrollFrame.player5TotalBankrollTableDisplay:GetText(), "%d+"))

        if playerFrame.player5HitButton:IsShown() then
            if player5currentBankroll - player5MainBet < 0 then
                print("You do not have enough gold in your bankroll to split your hand. Please visit the Cash Desk.")
            else

                SendChatMessage("[P5] Split", "RAID")
                playerFrame.player5HitButton:Hide()
                playerFrame.player5StandButton:Hide()
                playerFrame.player5DoubleButton:Hide()
                playerFrame.player5SplitButton:Hide()
                playerFrame.player5InsuranceYesButton:Hide()
                playerFrame.player5InsuranceNoButton:Hide()
                playerFrame.player5InsuranceTitle:Hide()
                playerFrame.player5InsuranceSubtitle:Hide()
                player5ConfirmMainBetButton:Hide()
                player5MainBetEditBox:Hide()
                playerFrame.player5MainBetTitle:Hide()
                

                playerFrame.player5SplitH1Title:Show()
                playerFrame.player5SplitH2Title:Show()
                player5SplitH1EditBox:Show()
                player5SplitH2EditBox:Show()
                playerFrame.player5HitButtonSplitH1:Show()
                playerFrame.player5StandButtonSplitH1:Show()
                playerFrame.player5DoubleButtonSplitH1:Show()
                playerFrame.player5HitButtonSplitH2:Show()
                playerFrame.player5StandButtonSplitH2:Show()
                playerFrame.player5DoubleButtonSplitH2:Show()

                betAmount5 = tonumber(player5MainBetEditBox:GetText())
                if betAmount5 then
                    player5SplitH1EditBox:SetText(betAmount5)
                    player5SplitH2EditBox:SetText(betAmount5)
                end

                if playerFrame.dealerCardTotalText:GetText() == "1 or 11" and playerFrame.player5InsuranceYesButton:IsEnabled() and playerFrame.player5InsuranceNoButton:IsEnabled() then
                    SendChatMessage("[P5] NO to Insurance", "RAID")
                    playerFrame.player5InsuranceYesButton:Disable()
                    playerFrame.player5InsuranceNoButton:Disable()
                    player5InsuranceNoIcon:Show()
                end

                timerReset()
            end
        else
            print("You must wait until its your turn.")
        end
    else
        print("You must wait until its your turn.")
    end 
end)
playerFrame.player5DealNowButton:SetScript("OnClick", function()
    SendChatMessage("{moon} " .. playerName .. " has indicated they are ready.", "RAID")
    -- Player 5 bet buttons disabled
    player5ConfirmMainBetButton:Disable()
    player5ConfirmPPBetButton:Disable()
    player5Confirm213BetButton:Disable()
    player5PreloadBetButton:Disable()
    playerFrame.player5DealNowButton:Disable()
end)








-- "Return" button
cashDeskFrame.returnButton:SetScript("OnClick", function(self, button, down)
    PlaySoundFile(soundFilePaths[113])
    if button == "LeftButton" then
        cashDeskFrame:Hide()
        stepsFrame:Hide()
        stepsFrame.dealerImage:Hide()
        stepsFrame2:Hide()
        stepsFrame2.dealerImage2:Hide()
        playerFrame:Show()
        bankrollFrame:Show()
        buyInEditBox:SetText("")
        cashOutEditBox:SetText("")
    end
end)
-- "Cash-Out" button
cashDeskFrame.cashOutButton:SetScript("OnClick", function(self, button, down)
    if playerName == unitName1 then
        player1CashOut()
    elseif playerName == unitName2 then
        player2CashOut()
    elseif playerName == unitName3 then
        player3CashOut()
    elseif playerName == unitName4 then
        player4CashOut()
    elseif playerName == unitName5 then
        player5CashOut()
    else
        print("You are not sitting at the table.")
    end
end)
-- "Buy-In" button
cashDeskFrame.buyInButton:SetScript("OnClick", function(self, button, down)
    if playerName == unitName1 then
        player1BuyIn()
    elseif playerName == unitName2 then
        player2BuyIn()
    elseif playerName == unitName3 then
        player3BuyIn()
    elseif playerName == unitName4 then
        player4BuyIn()
    elseif playerName == unitName5 then
        player5BuyIn()
    else
        print("You are not sitting at the table.")
    end
end)




player1dealtCardsFrameSplitH1.playerH2CardsButton:SetScript("OnClick", function(self, button, down)

    player1dealtCardsFrameSplitH2:Show()
    player1dealtCardsFrameSplitH2.playerH1CardsButton:Show()
    player1dealtCardsFrameSplitH2.playerH2CardsButton:Show()
    player1dealtCardsFrameSplitH1:Hide()
    player1dealtCardsFrameSplitH1.playerH1CardsButton:Hide()
    player1dealtCardsFrameSplitH1.playerH2CardsButton:Hide()

end)
player1dealtCardsFrameSplitH2.playerH1CardsButton:SetScript("OnClick", function(self, button, down)

    player1dealtCardsFrameSplitH1:Show()
    player1dealtCardsFrameSplitH1.playerH1CardsButton:Show()
    player1dealtCardsFrameSplitH1.playerH2CardsButton:Show()
    player1dealtCardsFrameSplitH2:Hide()
    player1dealtCardsFrameSplitH2.playerH1CardsButton:Hide()
    player1dealtCardsFrameSplitH2.playerH2CardsButton:Hide()

end)

player2dealtCardsFrameSplitH1.playerH2CardsButton:SetScript("OnClick", function(self, button, down)

    player2dealtCardsFrameSplitH2:Show()
    player2dealtCardsFrameSplitH2.playerH1CardsButton:Show()
    player2dealtCardsFrameSplitH2.playerH2CardsButton:Show()
    player2dealtCardsFrameSplitH1:Hide()
    player2dealtCardsFrameSplitH1.playerH1CardsButton:Hide()
    player2dealtCardsFrameSplitH1.playerH2CardsButton:Hide()

end)
player2dealtCardsFrameSplitH2.playerH1CardsButton:SetScript("OnClick", function(self, button, down)

    player2dealtCardsFrameSplitH1:Show()
    player2dealtCardsFrameSplitH1.playerH1CardsButton:Show()
    player2dealtCardsFrameSplitH1.playerH2CardsButton:Show()
    player2dealtCardsFrameSplitH2:Hide()
    player2dealtCardsFrameSplitH2.playerH1CardsButton:Hide()
    player2dealtCardsFrameSplitH2.playerH2CardsButton:Hide()

end)

player3dealtCardsFrameSplitH1.playerH2CardsButton:SetScript("OnClick", function(self, button, down)

    player3dealtCardsFrameSplitH2:Show()
    player3dealtCardsFrameSplitH2.playerH1CardsButton:Show()
    player3dealtCardsFrameSplitH2.playerH2CardsButton:Show()
    player3dealtCardsFrameSplitH1:Hide()
    player3dealtCardsFrameSplitH1.playerH1CardsButton:Hide()
    player3dealtCardsFrameSplitH1.playerH2CardsButton:Hide()

end)
player3dealtCardsFrameSplitH2.playerH1CardsButton:SetScript("OnClick", function(self, button, down)

    player3dealtCardsFrameSplitH1:Show()
    player3dealtCardsFrameSplitH1.playerH1CardsButton:Show()
    player3dealtCardsFrameSplitH1.playerH2CardsButton:Show()
    player3dealtCardsFrameSplitH2:Hide()
    player3dealtCardsFrameSplitH2.playerH1CardsButton:Hide()

end)

player4dealtCardsFrameSplitH1.playerH2CardsButton:SetScript("OnClick", function(self, button, down)

    player4dealtCardsFrameSplitH2:Show()
    player4dealtCardsFrameSplitH2.playerH1CardsButton:Show()
    player4dealtCardsFrameSplitH2.playerH2CardsButton:Show()
    player4dealtCardsFrameSplitH1:Hide()
    player4dealtCardsFrameSplitH1.playerH1CardsButton:Hide()
    player4dealtCardsFrameSplitH1.playerH2CardsButton:Hide()

end)
player4dealtCardsFrameSplitH2.playerH1CardsButton:SetScript("OnClick", function(self, button, down)

    player4dealtCardsFrameSplitH1:Show()
    player4dealtCardsFrameSplitH1.playerH1CardsButton:Show()
    player4dealtCardsFrameSplitH1.playerH2CardsButton:Show()
    player4dealtCardsFrameSplitH2:Hide()
    player4dealtCardsFrameSplitH2.playerH1CardsButton:Hide()
    player4dealtCardsFrameSplitH2.playerH2CardsButton:Hide()

end)

player5dealtCardsFrameSplitH1.playerH2CardsButton:SetScript("OnClick", function(self, button, down)

    player5dealtCardsFrameSplitH2:Show()
    player5dealtCardsFrameSplitH2.playerH1CardsButton:Show()
    player5dealtCardsFrameSplitH2.playerH2CardsButton:Show()
    player5dealtCardsFrameSplitH1:Hide()
    player5dealtCardsFrameSplitH1.playerH1CardsButton:Hide()
    player5dealtCardsFrameSplitH1.playerH2CardsButton:Hide()

end)
player5dealtCardsFrameSplitH2.playerH1CardsButton:SetScript("OnClick", function(self, button, down)

    player5dealtCardsFrameSplitH1:Show()
    player5dealtCardsFrameSplitH1.playerH1CardsButton:Show()
    player5dealtCardsFrameSplitH1.playerH2CardsButton:Show()
    player5dealtCardsFrameSplitH2:Hide()
    player5dealtCardsFrameSplitH2.playerH1CardsButton:Hide()
    player5dealtCardsFrameSplitH2.playerH2CardsButton:Hide()

end)







-- "Select Your Role" button click
launchFrame.selectRoleButton:SetScript("OnClick", function()
    launchFrame.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\newUI2.tga")
    launchFrame.selectRoleButton:Hide()
    launchFrame.selectButtonPlayer:Show()
    launchFrame.selectButtonDealer:Show()
    launchFrame.goBackButton:Show()
    ResetFramePosition()
end)
-- "Return" button click - Role Select Screen
launchFrame.goBackButton:SetScript("OnClick", function()
    launchFrame.background:SetTexture("Interface\\AddOns\\Blackjack_Retail\\Images\\newUI.tga")
    launchFrame.selectRoleButton:Show()
    launchFrame.selectButtonPlayer:Hide()
    launchFrame.selectButtonDealer:Hide()
    launchFrame.goBackButton:Hide()
    ResetFramePosition()
end)
-- Player "Select" button click
launchFrame.selectButtonPlayer:SetScript("OnClick", function()
    launchFrame:Hide()
    launchFrame2:Show()
    ResetFramePosition()
end)
-- Dealer "Select" button click
launchFrame.selectButtonDealer:SetScript("OnClick", function()
    ResetFramePosition()
    if IsInRaid() then
        if UnitIsGroupLeader("player") then
            SendChatMessage("{moon} " .. playerName .. " has selected DEALER", "RAID")
            launchFrame:Hide()
            launchFrame3:Show()
        else
            dealerDeniedFrame:Show()
        end
    else
        dealerDeniedFrame:Show()
    end
    
end)

launchFrame3.openTableButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        if termsAgreed == true then
            launchFrame3:Hide()
            dealerFrameDAO:Show()
            tableLimitsFrameDAO:Show()
            tableLimitsTitleFrameDAO:Show()
            tableLimitsTextFrameDAO:Show()
            bankingFrameDAO:Show()
            SendChatMessage("I have opened the table.", "RAID")
            local dealerNameDAO = UnitName("player");
            SendChatMessage("Table ID: " .. currentDecksDAO .. "." .. minBetMain .. "." .. minBetPP .. "." .. maxBetMain .. "." .. maxBetPP .. "." .. mixedPairPayoutDAO .. "." .. colouredPairPayoutDAO .. "." .. perfectPairPayoutDAO .. "." .. flushPayoutDAO .. "." .. straightPayoutDAO .. "." .. threeOfAKindPayoutDAO .. "." .. straightFlushPayoutDAO .. "." .. suitedThreeOfAKindPayoutDAO, "RAID")
            if dealerNameDAO then
                SendChatMessage("Dealer: " .. dealerNameDAO, "RAID")
            end
            if unitName1DAO then
                SendChatMessage("{cross} Seat 1: " .. unitName1DAO, "RAID")
            else
                SendChatMessage("{triangle} Seat 1: Available", "RAID")
            end
            if unitName2DAO then
                SendChatMessage("{cross} Seat 2: " .. unitName2DAO, "RAID")
            else
                SendChatMessage("{triangle} Seat 2: Available", "RAID")
            end
            if unitName3DAO then
                SendChatMessage("{cross} Seat 3: " .. unitName3DAO, "RAID")
            else
                SendChatMessage("{triangle} Seat 3: Available", "RAID")
            end
            if unitName4DAO then
                SendChatMessage("{cross} Seat 4: " .. unitName4DAO, "RAID")
            else
                SendChatMessage("{triangle} Seat 4: Available", "RAID")
            end
            if unitName5DAO then
                SendChatMessage("{cross} Seat 5: " .. unitName5DAO, "RAID")
            else
                SendChatMessage("{triangle} Seat 5: Available", "RAID")
            end
        else
            dealerStepsCheckFrame:Show()
            launchFrame3.openTableButton:Disable()
        end
    end
end)

dealerStepsCheckFrame.continueButton:SetScript("OnClick", function()
    dealerStepsCheckFrame:Hide()
    launchFrame3.openTableButton:Enable()
    ResetFramePosition()
end)
-- "Return" button click - Player Screen
launchFrame3.goBackButton:SetScript("OnClick", function()
    launchFrame3:Hide()
    launchFrame:Show()
    ResetFramePosition()
end)
dealerDeniedFrame.closeButton:SetScript("OnClick", function()
    dealerDeniedFrame:Hide()
end)
-- "Return" button click - Player Screen
launchFrame2.goBackButton2:SetScript("OnClick", function()
    launchFrame2:Hide()
    launchFrame:Show()
    ResetFramePosition()
end)
-- "Join Table" button - Player Screen
launchFrame2.joinButton:SetScript("OnClick", function(self, button, down)
    PlaySoundFile(soundFilePaths[116])
    if button == "LeftButton" then
        launchFrame2:Hide()
        playerFrame:Show()
        bankrollFrame:Show()
        tableLimitsFrame:Show()
        tableLimitsTitleFrame:Show()
        tableLimitsTextFrame:Show()
        SendChatMessage("{circle} " .. playerName .. " has joined the table.", "RAID")
        tableSpectator = true
    end
end)

launchFrame2.rulesButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        launchFrame2:Hide()
        rulesFrame2:Show()
        ResetFramePosition()
    end
end)

launchFrame2.faqsButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        launchFrame2:Hide()
        faqsFrame:Show()
        ResetFramePosition()
    end
end)

launchFrame2.tutorialButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        launchFrame2:Hide()
        tutorialFrame:Show()
        ResetFramePosition()
    end
end)

launchFrame3.rulesButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        launchFrame3:Hide()
        rulesFrame2Dealer:Show()
        ResetFramePosition()
    end
end)

launchFrame3.faqsButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        launchFrame3:Hide()
        faqsFrameDealer:Show()
        ResetFramePosition()
    end
end)

launchFrame3.tutorialButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        launchFrame3:Hide()
        tutorialFrameDealer2:Show()
        ResetFramePosition()
    end
end)

tutorialFrame.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrame:Hide()
        launchFrame2:Show()
        ResetFramePosition()
    end
end)

tutorialFrame.dealerButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrame:Hide()
        tutorialFrame2:Show()
        ResetFramePosition()
    end
end)

tutorialFrame2.playerButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrame2:Hide()
        tutorialFrame:Show()
        ResetFramePosition()
    end
end)

tutorialFrame2.nextPageButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrame2:Hide()
        tutorialFrame3:Show()
        ResetFramePosition()
    end
end)

tutorialFrame2.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrame2:Hide()
        launchFrame2:Show()
        ResetFramePosition()
    end
end)

tutorialFrame3.previousPageButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrame3:Hide()
        tutorialFrame2:Show()
        ResetFramePosition()
    end
end)

tutorialFrame3.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrame3:Hide()
        launchFrame2:Show()
        ResetFramePosition()
    end
end)

tutorialFrame3.playerButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrame3:Hide()
        tutorialFrame:Show()
        ResetFramePosition()
    end
end)

faqsFrame.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        faqsFrame:Hide()
        launchFrame2:Show()
        ResetFramePosition()
    end
end)

rulesFrame2.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        rulesFrame2:Hide()
        launchFrame2:Show()
        ResetFramePosition()
    end
end)

rulesFrame2.nextPageButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        rulesFrame2:Hide()
        rulesFrame3:Show()
        ResetFramePosition()
    end
end)

rulesFrameTable1.nextPageButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        rulesFrameTable1:Hide()
        rulesFrameTable2:Show()
    end
end)

rulesFrameTable2.previousPageButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        rulesFrameTable2:Hide()
        rulesFrameTable1:Show()
    end
end)

rulesFrame3.previousPageButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        rulesFrame3:Hide()
        rulesFrame2:Show()
        ResetFramePosition()
    end
end)

rulesFrame3.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        rulesFrame3:Hide()
        launchFrame2:Show()
        ResetFramePosition()
    end
end)

tutorialFrameDealer.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrameDealer:Hide()
        launchFrame3:Show()
        ResetFramePosition()
    end
end)

tutorialFrameDealer.dealerButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrameDealer:Hide()
        tutorialFrameDealer2:Show()
        ResetFramePosition()
    end
end)

tutorialFrameDealer2.playerButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrameDealer2:Hide()
        tutorialFrameDealer:Show()
        ResetFramePosition()
    end
end)

tutorialFrameDealer2.nextPageButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrameDealer2:Hide()
        tutorialFrameDealer3:Show()
        ResetFramePosition()
    end
end)

tutorialFrameDealer2.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrameDealer2:Hide()
        launchFrame3:Show()
        ResetFramePosition()
    end
end)

tutorialFrameDealer3.previousPageButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrameDealer3:Hide()
        tutorialFrameDealer2:Show()
        ResetFramePosition()
    end
end)

tutorialFrameDealer3.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrameDealer3:Hide()
        launchFrame3:Show()
        ResetFramePosition()
    end
end)

tutorialFrameDealer3.playerButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        tutorialFrameDealer3:Hide()
        tutorialFrameDealer:Show()
        ResetFramePosition()
    end
end)

faqsFrameDealer.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        faqsFrameDealer:Hide()
        launchFrame3:Show()
        ResetFramePosition()
    end
end)

rulesFrame2Dealer.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        rulesFrame2Dealer:Hide()
        launchFrame3:Show()
        ResetFramePosition()
    end
end)

rulesFrame2Dealer.nextPageButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        rulesFrame2Dealer:Hide()
        rulesFrame3Dealer:Show()
        ResetFramePosition()
    end
end)

rulesFrame3Dealer.previousPageButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        rulesFrame3Dealer:Hide()
        rulesFrame2Dealer:Show()
        ResetFramePosition()
    end
end)

rulesFrame3Dealer.returnButton:SetScript("OnClick", function(self, button, down)
    if button == "LeftButton" then
        rulesFrame3Dealer:Hide()
        launchFrame3:Show()
        ResetFramePosition()
    end
end)


-- "Menu" button click
playerFrame.menuButton:SetScript("OnClick", function()
    if menuFrame:IsShown() then
        menuFrame:Hide()
    else
        menuFrame:Show()
    end
end)
-- "Cash Desk" button click
playerFrame.cashDeskButton:SetScript("OnClick", function(self, button, down)
    PlaySoundFile(soundFilePaths[114])
    if button == "LeftButton" then
        cashDeskFrame:Show()
        stepsFrame:Show()
        stepsFrame.dealerImage:Show()
        stepsFrame2:Show()
        stepsFrame2.dealerImage2:Show()
    end
    if playerName == unitName1 then
        cashDeskFrame.player1TotalBankroll:Show()
    elseif playerName == unitName2 then
        cashDeskFrame.player2TotalBankroll:Show()
    elseif playerName == unitName3 then
        cashDeskFrame.player3TotalBankroll:Show()
    elseif playerName == unitName4 then
        cashDeskFrame.player4TotalBankroll:Show()
    elseif playerName == unitName5 then
        cashDeskFrame.player5TotalBankroll:Show()
    end 
end)
-- "Leave Table" button click
playerFrame.leaveTableButton:SetScript("OnClick", function()
    PlaySoundFile(soundFilePaths[117])
    -- Handle the "leaving" action, communicate with players, and change game state
    playerFrame:Hide()
    bankrollFrame:Hide()
    preloadFrame:Hide()
    historyFrame:Hide()
    payoutsFrame:Hide()
    sideBetWinFramePP:Hide()
    sideBetWinFrame213:Hide()
    player1dealtCardsFrame:Hide()
    player1dealtCardsFrameSplitH1:Hide()
    player1dealtCardsFrameSplitH1:Hide()
    player2dealtCardsFrame:Hide()
    player2dealtCardsFrameSplitH1:Hide()
    player2dealtCardsFrameSplitH1:Hide()
    player3dealtCardsFrame:Hide()
    player3dealtCardsFrameSplitH1:Hide()
    player3dealtCardsFrameSplitH1:Hide()
    player4dealtCardsFrame:Hide()
    player4dealtCardsFrameSplitH1:Hide()
    player4dealtCardsFrameSplitH1:Hide()
    player5dealtCardsFrame:Hide()
    player5dealtCardsFrameSplitH1:Hide()
    player5dealtCardsFrameSplitH1:Hide()
    chatWindowFrame:Hide()
end)
-- "Rules" button click
menuFrame.rulesButton:SetScript("OnClick", function()
    if rulesFrameTable1:IsShown() then
        rulesFrameTable1:Hide()
    else
        rulesFrameTable1:Show()
    end
end)
-- "Payouts" button click
menuFrame.payoutsButton:SetScript("OnClick", function()
    if payoutsFrame:IsShown() then
        payoutsFrame:Hide()
        payoutsFrame.mainBetsTitle:Hide()
        payoutsFrame.sideBetsTitle:Hide()
        payoutsFrame.perfectPairsTitle:Hide()
        payoutsFrame.perfectPairsExplain:Hide()
        payoutsFrame.t213Title:Hide()
        payoutsFrame.t213Explain:Hide()
        payoutsFrame.t213Explain2:Hide()
        payoutsFrame.t213Explain3:Hide()
        payoutsFrame.t213Explain4:Hide()
        payoutsFrame.t213Explain5:Hide()
        payoutsFrame.t213Explain6:Hide()
        payoutsFrame.mainBetStandard:Hide()
        payoutsFrame.standardPayout:Hide()
        payoutsFrame.mainBetBlackjack:Hide()
        payoutsFrame.blackjackPayout:Hide()
        payoutsFrame.mixedPairPP:Hide()
        payoutsFrame.mixedPairPayout:Hide()
        payoutsFrame.colouredPairPP:Hide()
        payoutsFrame.colouredPairPayout:Hide()
        payoutsFrame.perfectPairPP:Hide()
        payoutsFrame.perfectPairPayout:Hide()
        payoutsFrame.flush213:Hide()
        payoutsFrame.flushPayout:Hide()
        payoutsFrame.straight213:Hide()
        payoutsFrame.straightPayout:Hide()
        payoutsFrame.threeOfAKind213:Hide()
        payoutsFrame.threeOfAKindPayout:Hide()
        payoutsFrame.straightFlush213:Hide()
        payoutsFrame.straightFlushPayout:Hide()
        payoutsFrame.suitedThreeOfAKind213:Hide()
        payoutsFrame.suitedThreeOfAKindPayout:Hide()
        payoutsFrame.card1image:Hide()
        payoutsFrame.card2image:Hide()
        payoutsFrame.card3image:Hide()
        payoutsFrame.card4image:Hide()
        payoutsFrame.card5image:Hide()
        payoutsFrame.card6image:Hide()
        payoutsFrame.card7image:Hide()
        payoutsFrame.card8image:Hide()
        payoutsFrame.card9image:Hide()
        payoutsFrame.card10image:Hide()
        payoutsFrame.card11image:Hide()
        payoutsFrame.card12image:Hide()
        payoutsFrame.card13image:Hide()
        payoutsFrame.card14image:Hide()
        payoutsFrame.card15image:Hide()
        payoutsFrame.card16image:Hide()
        payoutsFrame.card17image:Hide()
        payoutsFrame.card18image:Hide()
        payoutsFrame.card19image:Hide()
        payoutsFrame.card20image:Hide()
        payoutsFrame.card21image:Hide()
        payoutsFrame.card22image:Hide()
        payoutsFrame.card23image:Hide()
        payoutsFrame.card24image:Hide()
        payoutsFrame.card25image:Hide()
    else
        payoutsFrame:Show()
        payoutsFrame.mainBetsTitle:Show()
        payoutsFrame.sideBetsTitle:Show()
        payoutsFrame.perfectPairsTitle:Show()
        payoutsFrame.perfectPairsExplain:Show()
        payoutsFrame.t213Title:Show()
        payoutsFrame.t213Explain:Show()
        payoutsFrame.t213Explain2:Show()
        payoutsFrame.t213Explain3:Show()
        payoutsFrame.t213Explain4:Show()
        payoutsFrame.t213Explain5:Show()
        payoutsFrame.t213Explain6:Show()
        payoutsFrame.mainBetStandard:Show()
        payoutsFrame.standardPayout:Show()
        payoutsFrame.mainBetBlackjack:Show()
        payoutsFrame.blackjackPayout:Show()
        payoutsFrame.mixedPairPP:Show()
        payoutsFrame.mixedPairPayout:Show()
        payoutsFrame.colouredPairPP:Show()
        payoutsFrame.colouredPairPayout:Show()
        payoutsFrame.perfectPairPP:Show()
        payoutsFrame.perfectPairPayout:Show()
        payoutsFrame.flush213:Show()
        payoutsFrame.flushPayout:Show()
        payoutsFrame.straight213:Show()
        payoutsFrame.straightPayout:Show()
        payoutsFrame.threeOfAKind213:Show()
        payoutsFrame.threeOfAKindPayout:Show()
        payoutsFrame.straightFlush213:Show()
        payoutsFrame.straightFlushPayout:Show()
        payoutsFrame.suitedThreeOfAKind213:Show()
        payoutsFrame.suitedThreeOfAKindPayout:Show()
        payoutsFrame.card1image:Show()
        payoutsFrame.card2image:Show()
        payoutsFrame.card3image:Show()
        payoutsFrame.card4image:Show()
        payoutsFrame.card5image:Show()
        payoutsFrame.card6image:Show()
        payoutsFrame.card7image:Show()
        payoutsFrame.card8image:Show()
        payoutsFrame.card9image:Show()
        payoutsFrame.card10image:Show()
        payoutsFrame.card11image:Show()
        payoutsFrame.card12image:Show()
        payoutsFrame.card13image:Show()
        payoutsFrame.card14image:Show()
        payoutsFrame.card15image:Show()
        payoutsFrame.card16image:Show()
        payoutsFrame.card17image:Show()
        payoutsFrame.card18image:Show()
        payoutsFrame.card19image:Show()
        payoutsFrame.card20image:Show()
        payoutsFrame.card21image:Show()
        payoutsFrame.card22image:Show()
        payoutsFrame.card23image:Show()
        payoutsFrame.card24image:Show()
        payoutsFrame.card25image:Show()
    end
end)
-- "History" button click
playerFrame.historyButton:SetScript("OnClick", function()

    if historyFrame:IsShown() then
        historyFrame:Hide()
        historyFrame.totalWageredText:Hide()
        historyFrame.totalWonText:Hide()
        historyFrame.totalLostText:Hide()
        historyFrame.ProfitText:Hide()

        if playerName == unitName1 then
            historyFrame.player1totalWageredAmount:Hide()
            historyFrame.player1totalWonAmount:Hide()
            historyFrame.player1totalLostAmount:Hide()
            historyFrame.player1ProfitAmount:Hide()
        elseif playerName == unitName2 then
            historyFrame.player2totalWageredAmount:Hide()
            historyFrame.player2totalWonAmount:Hide()
            historyFrame.player2totalLostAmount:Hide()
            historyFrame.player2ProfitAmount:Hide()
        end

    else
        historyFrame:Show()
        historyFrame.totalWageredText:Show()
        historyFrame.totalWonText:Show()
        historyFrame.totalLostText:Show()
        historyFrame.ProfitText:Show()

        if playerName == unitName1 then
            historyFrame.player1totalWageredAmount:Show()
            historyFrame.player1totalWonAmount:Show()
            historyFrame.player1totalLostAmount:Show()
            historyFrame.player1ProfitAmount:Show()
        elseif playerName == unitName2 then
            historyFrame.player2totalWageredAmount:Show()
            historyFrame.player2totalWonAmount:Show()
            historyFrame.player2totalLostAmount:Show()
            historyFrame.player2ProfitAmount:Show()
        end

    end
end)
-- "Rebet" button click
menuFrame.preloadButton:SetScript("OnClick", function()

    if preloadFrame:IsShown() then
        preloadFrame:Hide()
        preloadFrame.preloadMainBetText:Hide()
        preloadFrame.preloadPPBetText:Hide()
        preloadFrame.preload213BetText:Hide()

        if playerName == unitName1 then
            player1PreloadEditBoxMainBet:Hide()
            player1PreloadEditBoxPPBet:Hide()
            player1PreloadEditBox213Bet:Hide()
            player1PreloadBetButton:Hide()
        elseif playerName == unitName2 then
            player2PreloadEditBoxMainBet:Hide()
            player2PreloadEditBoxPPBet:Hide()
            player2PreloadEditBox213Bet:Hide()
            player2PreloadBetButton:Hide()
        end

    else
        preloadFrame:Show()
        preloadFrame.preloadMainBetText:Show()
        preloadFrame.preloadPPBetText:Show()
        preloadFrame.preload213BetText:Show()

        if playerName == unitName1 then
            player1PreloadEditBoxMainBet:Show()
            player1PreloadEditBoxPPBet:Show()
            player1PreloadEditBox213Bet:Show()
            player1PreloadBetButton:Show()
        elseif playerName == unitName2 then
            player2PreloadEditBoxMainBet:Show()
            player2PreloadEditBoxPPBet:Show()
            player2PreloadEditBox213Bet:Show()
            player2PreloadBetButton:Show()
        elseif playerName == unitName3 then
            player3PreloadEditBoxMainBet:Show()
            player3PreloadEditBoxPPBet:Show()
            player3PreloadEditBox213Bet:Show()
            player3PreloadBetButton:Show()
        elseif playerName == unitName4 then
            player4PreloadEditBoxMainBet:Show()
            player4PreloadEditBoxPPBet:Show()
            player4PreloadEditBox213Bet:Show()
            player4PreloadBetButton:Show()
        elseif playerName == unitName5 then
            player5PreloadEditBoxMainBet:Show()
            player5PreloadEditBoxPPBet:Show()
            player5PreloadEditBox213Bet:Show()
            player5PreloadBetButton:Show()
        end

    end
end)
-- "Cards" button click
menuFrame.cardsButton:SetScript("OnClick", function()

    if playerName == unitName1 then

        if player1dealtCardsFrame:IsShown() then
            player1dealtCardsFrame:Hide()
            player1dealtCardsFrame.playerCardsButton:Hide()
        else
            if player1SplitToggle == true then
                player1dealtCardsFrameSplitH1:Show()
                player1dealtCardsFrameSplitH1.playerH1CardsButton:Show()
                player1dealtCardsFrameSplitH1.playerH2CardsButton:Show()
            else
                player1dealtCardsFrame:Show()
                player1dealtCardsFrame.playerCardsButton:Show()
                if gameRunning == false then
                    player1dealtCardsFrame.notStartedYetText:Show()
                else
                end
            end
        end

    elseif playerName == unitName2 then

        if player2dealtCardsFrame:IsShown() then
            player2dealtCardsFrame:Hide()
            player2dealtCardsFrame.playerCardsButton:Hide()
        else
            if player2SplitToggle == true then
                player2dealtCardsFrameSplitH1:Show()
                player2dealtCardsFrameSplitH1.playerH1CardsButton:Show()
                player2dealtCardsFrameSplitH1.playerH2CardsButton:Show()
            else
                player2dealtCardsFrame:Show()
                player2dealtCardsFrame.playerCardsButton:Show()
                if gameRunning == false then
                    player2dealtCardsFrame.notStartedYetText:Show()
                else
                end
            end
        end
    
    elseif playerName == unitName3 then

        if player3dealtCardsFrame:IsShown() then
            player3dealtCardsFrame:Hide()
            player3dealtCardsFrame.playerCardsButton:Hide()
        else
            if player3SplitToggle == true then
                player3dealtCardsFrameSplitH1:Show()
                player3dealtCardsFrameSplitH1.playerH1CardsButton:Show()
                player3dealtCardsFrameSplitH1.playerH2CardsButton:Show()
            else
                player3dealtCardsFrame:Show()
                player3dealtCardsFrame.playerCardsButton:Show()
                if gameRunning == false then
                    player3dealtCardsFrame.notStartedYetText:Show()
                else
                end
            end
        end
    
    elseif playerName == unitName4 then

        if player4dealtCardsFrame:IsShown() then
            player4dealtCardsFrame:Hide()
            player4dealtCardsFrame.playerCardsButton:Hide()
        else
            if player4SplitToggle == true then
                player4dealtCardsFrameSplitH1:Show()
                player4dealtCardsFrameSplitH1.playerH1CardsButton:Show()
                player4dealtCardsFrameSplitH1.playerH2CardsButton:Show()
            else
                player4dealtCardsFrame:Show()
                player4dealtCardsFrame.playerCardsButton:Show()
                if gameRunning == false then
                    player4dealtCardsFrame.notStartedYetText:Show()
                else
                end
            end
        end
    
    elseif playerName == unitName5 then

        if player5dealtCardsFrame:IsShown() then
            player5dealtCardsFrame:Hide()
            player5dealtCardsFrame.playerCardsButton:Hide()
        else
            if player5SplitToggle == true then
                player5dealtCardsFrameSplitH1:Show()
                player5dealtCardsFrameSplitH1.playerH1CardsButton:Show()
                player5dealtCardsFrameSplitH1.playerH2CardsButton:Show()
            else
                player5dealtCardsFrame:Show()
                player5dealtCardsFrame.playerCardsButton:Show()
                if gameRunning == false then
                    player5dealtCardsFrame.notStartedYetText:Show()
                else
                end
            end
        end

    end
end)
-- "Chat Log" button click
menuFrame.chatLogButton:SetScript("OnClick", function()

    if chatWindowFrame:IsShown() then
        chatWindowFrame:Hide()
    else
        chatWindowFrame:Show()
    end

end)


playerFrame:SetScript("OnMouseDown", function(self, button)
    if button == "LeftButton" then
        -- >> PLAYER 1 <<
        player1MainBetEditBox:ClearFocus()
        player1PPBetEditBox:ClearFocus()
        player1213BetEditBox:ClearFocus()
        player1PreloadEditBoxMainBet:ClearFocus()
        player1PreloadEditBoxPPBet:ClearFocus()
        player1PreloadEditBox213Bet:ClearFocus()

        -- >> PLAYER 2 <<
        player2MainBetEditBox:ClearFocus()
        player2PPBetEditBox:ClearFocus()
        player2213BetEditBox:ClearFocus()  
        player2PreloadEditBoxMainBet:ClearFocus()
        player2PreloadEditBoxPPBet:ClearFocus()
        player2PreloadEditBox213Bet:ClearFocus()

        -- >> PLAYER 3 <<
        player3MainBetEditBox:ClearFocus()
        player3PPBetEditBox:ClearFocus()
        player3213BetEditBox:ClearFocus()  
        player3PreloadEditBoxMainBet:ClearFocus()
        player3PreloadEditBoxPPBet:ClearFocus()
        player3PreloadEditBox213Bet:ClearFocus()

        -- >> PLAYER 4 <<
        player4MainBetEditBox:ClearFocus()
        player4PPBetEditBox:ClearFocus()
        player4213BetEditBox:ClearFocus()  
        player4PreloadEditBoxMainBet:ClearFocus()
        player4PreloadEditBoxPPBet:ClearFocus()
        player4PreloadEditBox213Bet:ClearFocus()

        -- >> PLAYER 5 <<
        player5MainBetEditBox:ClearFocus()
        player5PPBetEditBox:ClearFocus()
        player5213BetEditBox:ClearFocus()  
        player5PreloadEditBoxMainBet:ClearFocus()
        player5PreloadEditBoxPPBet:ClearFocus()
        player5PreloadEditBox213Bet:ClearFocus()

        tipDealerEditBox:ClearFocus()
        
    end
end)

-- Slash command handler for the player
SlashCmdList["BLACKJACK"] = function(msg)
    if msg == "" then
        launchFrame:Show()
        chatFrame = SELECTED_DOCK_FRAME
        ChatFrame_OpenChat("/me", chatFrame)
        
        editBox = _G[chatFrame:GetName().."EditBox"]
        editBox:SetText("")
        editBox:Insert("/me has loaded up Blackjack on CurseForge.")
        
        ChatEdit_SendText(editBox)
        ChatEdit_DeactivateChat(editBox)
        -- Handle the "/blackjack" command
    else
        print("Invalid command. Usage: /blackjack")
    end
end

-- Register the slash command
SLASH_BLACKJACK1 = "/blackjack"
SLASH_BLACKJACK2 = "/bj"






























































































-- Creating the main DealerFrame window
dealerFrameDAO = CreateFrame("Frame", "BlackjackDealerFrame", UIParent, "BasicFrameTemplateWithInset")
dealerFrameDAO:SetSize(916, 515)
dealerFrameDAO:Hide()

-- Setting titleDAO for DealerFrame
dealerFrameDAO.titleDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.titleDAO:SetPoint("TOP", dealerFrameDAO, 15, -5)
dealerFrameDAO.titleDAO:SetText("Blackjack v5.0.2  -  Developed by Hyrav")

-- Setting background image (the playing table) for DealerFrame
backgroundImageDAO = dealerFrameDAO:CreateTexture(nil, "BACKGROUND")
backgroundImageDAO:SetSize(1510, 755)
backgroundImageDAO:SetPoint("CENTER", dealerFrameDAO, "BOTTOM", 0, 240)
backgroundImageDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\blackjackplayer.tga")
backgroundImageDAO:SetBlendMode("BLEND")
backgroundImageDAO:SetDrawLayer("ARTWORK")

-- "Open Table" buttonDAO which enables players to join
dealerFrameDAO.openTableButtonDAO = CreateFrame("Button", nil, dealerFrameDAO, "GameMenuButtonTemplate")
dealerFrameDAO.openTableButtonDAO:SetPoint("BOTTOMLEFT", dealerFrameDAO, 10, 35)
dealerFrameDAO.openTableButtonDAO:SetSize(83, 25)
dealerFrameDAO.openTableButtonDAO:SetText("Open Table")
dealerFrameDAO.openTableButtonDAO:SetNormalFontObject("GameFontWhiteSmall")
dealerFrameDAO.openTableButtonDAO:SetHighlightFontObject("GameFontWhiteSmall")

-- "Close Table" buttonDAO which kicks all players from the table
dealerFrameDAO.closeTableButtonDAO = CreateFrame("Button", nil, dealerFrameDAO, "GameMenuButtonTemplate")
dealerFrameDAO.closeTableButtonDAO:SetPoint("BOTTOMLEFT", dealerFrameDAO, 10, 10)
dealerFrameDAO.closeTableButtonDAO:SetSize(83, 25)
dealerFrameDAO.closeTableButtonDAO:SetText("Close Table")
dealerFrameDAO.closeTableButtonDAO:SetNormalFontObject("GameFontWhiteSmall")
dealerFrameDAO.closeTableButtonDAO:SetHighlightFontObject("GameFontWhiteSmall")

-- "New Game" buttonDAO which resets the game state back to fresh
dealerFrameDAO.newGameButtonDAO = CreateFrame("Button", nil, dealerFrameDAO, "GameMenuButtonTemplate")
dealerFrameDAO.newGameButtonDAO:SetPoint("BOTTOM", dealerFrameDAO, -123, 60)
dealerFrameDAO.newGameButtonDAO:SetSize(83, 25)
dealerFrameDAO.newGameButtonDAO:SetText("New Game")
dealerFrameDAO.newGameButtonDAO:SetNormalFontObject("GameFontWhiteSmall")
dealerFrameDAO.newGameButtonDAO:SetHighlightFontObject("GameFontWhiteSmall")

-- "Deal Cards" buttonDAO which deals cards individually
dealerFrameDAO.dealCardsButtonDAO = CreateFrame("Button", nil, dealerFrameDAO, "GameMenuButtonTemplate")
dealerFrameDAO.dealCardsButtonDAO:SetPoint("BOTTOM", dealerFrameDAO, -123, 10)
dealerFrameDAO.dealCardsButtonDAO:SetSize(83, 25)
dealerFrameDAO.dealCardsButtonDAO:SetText("Deal Cards")
dealerFrameDAO.dealCardsButtonDAO:SetNormalFontObject("GameFontWhiteSmall")
dealerFrameDAO.dealCardsButtonDAO:SetHighlightFontObject("GameFontWhiteSmall")

-- "Shuffle Cards" buttonDAO which resets the shoes to 6 decks
dealerFrameDAO.controlPanelButtonDAO = CreateFrame("Button", nil, dealerFrameDAO, "GameMenuButtonTemplate")
dealerFrameDAO.controlPanelButtonDAO:SetPoint("TOPLEFT", dealerFrameDAO, 10, -25)
dealerFrameDAO.controlPanelButtonDAO:SetSize(83, 25)
dealerFrameDAO.controlPanelButtonDAO:SetText("Control Panel")
dealerFrameDAO.controlPanelButtonDAO:SetNormalFontObject("GameFontWhiteSmall")
dealerFrameDAO.controlPanelButtonDAO:SetHighlightFontObject("GameFontWhiteSmall")

-- "Place Bets" buttonDAO which initiates a 30 second timer for players to place their bets
dealerFrameDAO.placeBetsButtonDAO = CreateFrame("Button", nil, dealerFrameDAO, "GameMenuButtonTemplate")
dealerFrameDAO.placeBetsButtonDAO:SetPoint("BOTTOM", dealerFrameDAO, -123, 35)
dealerFrameDAO.placeBetsButtonDAO:SetSize(83, 25)
dealerFrameDAO.placeBetsButtonDAO:SetText("Place Bets")
dealerFrameDAO.placeBetsButtonDAO:SetNormalFontObject("GameFontWhiteSmall")
dealerFrameDAO.placeBetsButtonDAO:SetHighlightFontObject("GameFontWhiteSmall")

-- Resets dealerFrameDAO to the center of the screen upon reload/login
local function ResetFramePositionDAO()
    dealerFrameDAO:ClearAllPoints()
    dealerFrameDAO:SetPoint("CENTER", 120, 0)
end

local frameDAO = CreateFrame("Frame")
frameDAO:RegisterEvent("PLAYER_LOGIN")
frameDAO:SetScript("OnEvent", ResetFramePositionDAO)

-- Enable click-and-drag functionality for the dealerFrameDAO
dealerFrameDAO:SetMovable(true)
dealerFrameDAO:EnableMouse(true)
dealerFrameDAO:RegisterForDrag("LeftButton")

-- Set the frameDAO's script for handling the drag
dealerFrameDAO:SetScript("OnDragStart", function(selfDAO)
    selfDAO:StartMoving()
end)

dealerFrameDAO:SetScript("OnDragStop", function(selfDAO)
    selfDAO:StopMovingOrSizing()
end)

dealerFrameDAO.dealerCardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.dealerCardTotalTextDAO:SetPoint("BOTTOM", dealerFrameDAO, "BOTTOM", 55, 97)
dealerFrameDAO.dealerCardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 20, "OUTLINE")
dealerFrameDAO.dealerCardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.dealerCardTotalTextDAO:SetText("")










local isFirstLoadDAO = true

function UpdateCardTableDAO()
    originalCardTableDAO = {}

    for deckDAO = 1, currentDecksDAO do
        for suitIndexDAO, suitDAO in ipairs(suitsDAO) do
            for rankIndexDAO, rankDAO in ipairs(ranksDAO) do
                local cardNameDAO

                if rankDAO == "Ace" then
                    cardNameDAO = "Ace of " .. suitDAO .. " (1 or 11)"
                elseif rankDAO == "Jack" or rankDAO == "Queen" or rankDAO == "King" then
                    cardNameDAO = rankDAO .. " of " .. suitDAO .. " (10)"
                else
                    cardNameDAO = rankDAO .. " of " .. suitDAO
                end

                table.insert(originalCardTableDAO, cardNameDAO)
            end
        end
    end

    if not isFirstLoadDAO then
        local messageDAO = "{diamond} Switching to a " .. currentDecksDAO .. "-deck shoe - total number of cards: " .. #originalCardTableDAO
        SendChatMessage(messageDAO, "RAID")
    end

    currentRollDAO = #originalCardTableDAO
    isFirstLoadDAO = false
end

-- Creating the controlPanelFrameDAO window
controlPanelFrameDAO = CreateFrame("Frame", "ControlPanelFrame", UIParent, "InsetFrameTemplate")
controlPanelFrameDAO:SetSize(200, 110)
controlPanelFrameDAO:SetPoint("TOPLEFT", dealerFrameDAO, 12, -53)
controlPanelFrameDAO:SetFrameStrata("HIGH")
controlPanelFrameDAO:SetFrameLevel(controlPanelFrameDAO:GetFrameLevel() + 105)
controlPanelFrameDAO:SetAlpha(0.93)
controlPanelFrameDAO:Hide()

local numberOfDecksTextDAO = controlPanelFrameDAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
numberOfDecksTextDAO:SetPoint("TOP", 0, -12)
numberOfDecksTextDAO:SetText("Number of Decks")

controlPanelFrameDAO.buttons = {}
local buttonWidthDAO = 23
local buttonHeightDAO = 20
local buttonSpacingDAO = 20
local rowSpacingDAO = 20

local function SetCurrentDecksDAO(deckNumberDAO)

    if controlPanelFrameDAO.buttons[deckNumberDAO]:SetChecked(true) then
        print("This number of decks is already in use.")
    else
        if currentDecksDAO ~= deckNumberDAO then
            currentDecksDAO = deckNumberDAO
            UpdateCardTableDAO()

            if controlPanelFrameDAO.buttons then
                for j = 1, 8 do
                    if controlPanelFrameDAO.buttons[j] then
                        controlPanelFrameDAO.buttons[j]:SetChecked(j == currentDecksDAO)
                    end
                end
            end
        end
    end
end

for iDAO = 1, 8 do
    local buttonDAO = CreateFrame("CheckButton", "DeckButton" .. iDAO, controlPanelFrameDAO, "UIRadioButtonTemplate")
    local rowDAO, colDAO

    if iDAO <= 4 then
        rowDAO, colDAO = 1, iDAO
    else
        rowDAO, colDAO = 2, iDAO - 4
    end

    buttonDAO:SetPoint("TOP", -((buttonWidthDAO + buttonSpacingDAO - 12) * 2) + (colDAO - 1) * (buttonWidthDAO + buttonSpacingDAO), -(rowDAO - 1) * (buttonHeightDAO + buttonSpacingDAO - rowSpacingDAO) - 30)
    buttonDAO:SetSize(buttonWidthDAO, buttonHeightDAO)
    buttonDAO:SetScript("OnClick", function()
        SetCurrentDecksDAO(iDAO)
    end)

    if not controlPanelFrameDAO.buttons then
        controlPanelFrameDAO.buttons = {}  -- Initialize as a table if not already
    end

    controlPanelFrameDAO.buttons[iDAO] = buttonDAO
    buttonDAO.text:SetPoint("LEFT", -6, 0)
    buttonDAO.text:SetText(iDAO)

    if iDAO == 6 then
        buttonDAO:SetChecked(true)
        SetCurrentDecksDAO(iDAO)
    end
end

-- "Shuffle Cards" buttonDAO which resets the shoe
controlPanelFrameDAO.shuffleDeckButtonDAO = CreateFrame("Button", nil, controlPanelFrameDAO, "GameMenuButtonTemplate")
controlPanelFrameDAO.shuffleDeckButtonDAO:SetPoint("TOP", controlPanelFrameDAO, 0, -75)
controlPanelFrameDAO.shuffleDeckButtonDAO:SetSize(83, 25)
controlPanelFrameDAO.shuffleDeckButtonDAO:SetText("Shuffle Deck")
controlPanelFrameDAO.shuffleDeckButtonDAO:SetNormalFontObject("GameFontWhiteSmall")
controlPanelFrameDAO.shuffleDeckButtonDAO:SetHighlightFontObject("GameFontWhiteSmall")

-- Creating the controlPanelFrame2DAO window
controlPanelFrame2DAO = CreateFrame("Frame", "ControlPanelFrame", UIParent, "InsetFrameTemplate")
controlPanelFrame2DAO:SetSize(200, 135)
controlPanelFrame2DAO:SetPoint("BOTTOM", controlPanelFrameDAO, 0, -135)
controlPanelFrame2DAO:SetFrameStrata("HIGH")
controlPanelFrame2DAO:SetFrameLevel(controlPanelFrame2DAO:GetFrameLevel() + 105)
controlPanelFrame2DAO:SetAlpha(0.93)
controlPanelFrame2DAO:Hide()

tableLimitsTextDAO = controlPanelFrame2DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
tableLimitsTextDAO:SetPoint("TOP", 0, -12)
tableLimitsTextDAO:SetText("Table Bet Limits")

mainBetTextDAO = controlPanelFrame2DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
mainBetTextDAO:SetPoint("TOPLEFT", 18, -48)
mainBetTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
mainBetTextDAO:SetText("Main:")

minLabelTextDAO = controlPanelFrame2DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
minLabelTextDAO:SetPoint("TOPLEFT", 57, -35)
minLabelTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
minLabelTextDAO:SetText("Minimum")

maxLabelTextDAO = controlPanelFrame2DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
maxLabelTextDAO:SetPoint("TOPLEFT", 126, -35)
maxLabelTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
maxLabelTextDAO:SetText("Maximum")

mainBetGTextDAO = controlPanelFrame2DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
mainBetGTextDAO:SetPoint("TOPLEFT", 101, -49)
mainBetGTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
mainBetGTextDAO:SetText("G - ")

mainBetGText2DAO = controlPanelFrame2DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
mainBetGText2DAO:SetPoint("TOPLEFT", 170, -49)
mainBetGText2DAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
mainBetGText2DAO:SetText("G")

-- Edit Box for Main Bet - Minimum
minMainBetEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame2DAO, "InputBoxTemplate")
minMainBetEditBoxDAO:SetSize(40, 29)
minMainBetEditBoxDAO:SetPoint("TOPLEFT", controlPanelFrame2DAO, 58, -39)
minMainBetEditBoxDAO:SetAutoFocus(false)
minMainBetEditBoxDAO:SetText("1000")

-- Edit Box for Main Bet - Maximum
maxMainBetEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame2DAO, "InputBoxTemplate")
maxMainBetEditBoxDAO:SetSize(40, 29)
maxMainBetEditBoxDAO:SetPoint("TOPLEFT", controlPanelFrame2DAO, 128, -39)
maxMainBetEditBoxDAO:SetAutoFocus(false)
maxMainBetEditBoxDAO:SetText("25000")

sideBetTextDAO = controlPanelFrame2DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sideBetTextDAO:SetPoint("TOPLEFT", 21, -75)
sideBetTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
sideBetTextDAO:SetText("Side:")

sideBetGTextDAO = controlPanelFrame2DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sideBetGTextDAO:SetPoint("TOPLEFT", 101, -76)
sideBetGTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
sideBetGTextDAO:SetText("G - ")

sideBetGText2DAO = controlPanelFrame2DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sideBetGText2DAO:SetPoint("TOPLEFT", 170, -76)
sideBetGText2DAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
sideBetGText2DAO:SetText("G")

-- Edit Box for Side Bet - Minimum
minSideBetEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame2DAO, "InputBoxTemplate")
minSideBetEditBoxDAO:SetSize(40, 29)
minSideBetEditBoxDAO:SetPoint("TOPLEFT", controlPanelFrame2DAO, 58, -66)
minSideBetEditBoxDAO:SetAutoFocus(false)
minSideBetEditBoxDAO:SetText("100")

-- Edit Box for Side Bet - Maximum
maxSideBetEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame2DAO, "InputBoxTemplate")
maxSideBetEditBoxDAO:SetSize(40, 29)
maxSideBetEditBoxDAO:SetPoint("TOPLEFT", controlPanelFrame2DAO, 128, -66)
maxSideBetEditBoxDAO:SetAutoFocus(false)
maxSideBetEditBoxDAO:SetText("2500")

-- "Update Limits" buttonDAO which resets the shoe
controlPanelFrame2DAO.updateLimitsButtonDAO = CreateFrame("Button", nil, controlPanelFrame2DAO, "GameMenuButtonTemplate")
controlPanelFrame2DAO.updateLimitsButtonDAO:SetPoint("TOP", controlPanelFrame2DAO, 0, -100)
controlPanelFrame2DAO.updateLimitsButtonDAO:SetSize(83, 25)
controlPanelFrame2DAO.updateLimitsButtonDAO:SetText("Update Limit")
controlPanelFrame2DAO.updateLimitsButtonDAO:SetNormalFontObject("GameFontWhiteSmall")
controlPanelFrame2DAO.updateLimitsButtonDAO:SetHighlightFontObject("GameFontWhiteSmall")

controlPanelFrame2DAO:SetScript("OnMouseDown", function(selfDAO, buttonDAO)
    if buttonDAO == "LeftButton" then
        minMainBetEditBoxDAO:ClearFocus()
        maxMainBetEditBoxDAO:ClearFocus()
        minSideBetEditBoxDAO:ClearFocus()
        maxSideBetEditBoxDAO:ClearFocus()
        colouredPairEditBoxDAO:ClearFocus()
        perfectPairEditBoxDAO:ClearFocus()
        flushEditBoxDAO:ClearFocus()
        straightEditBoxDAO:ClearFocus()
        threeOfAKindEditBoxDAO:ClearFocus()
        straightFlushEditBoxDAO:ClearFocus()
        suitedThreeOfAKindEditBoxDAO:ClearFocus()
    end
end)

-- Creating the controlPanelFrame3DAO window
controlPanelFrame3DAO = CreateFrame("Frame", "ControlPanelFrame", UIParent, "InsetFrameTemplate")
controlPanelFrame3DAO:SetSize(200, 245)
controlPanelFrame3DAO:SetPoint("TOPRIGHT", controlPanelFrameDAO, 200, 0)
controlPanelFrame3DAO:SetFrameStrata("HIGH")
controlPanelFrame3DAO:SetFrameLevel(controlPanelFrame3DAO:GetFrameLevel() + 105)
controlPanelFrame3DAO:SetAlpha(0.93)
controlPanelFrame3DAO:Hide()

sidebetPayoutsTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sidebetPayoutsTextDAO:SetPoint("TOP", 0, -12)
sidebetPayoutsTextDAO:SetText("Side Bet Payouts")

sidebetMixedPairTitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sidebetMixedPairTitleTextDAO:SetPoint("TOPLEFT", 13, -40)
sidebetMixedPairTitleTextDAO:SetText("Mixed Pair")
sidebetMixedPairTitleTextDAO:SetJustifyH("LEFT")
sidebetMixedPairTitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Edit Box for Mixed Pair
mixedPairEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame3DAO, "InputBoxTemplate")
mixedPairEditBoxDAO:SetSize(28, 15)
mixedPairEditBoxDAO:SetPoint("TOPRIGHT", controlPanelFrame3DAO, -27, -37)
mixedPairEditBoxDAO:SetAutoFocus(false)
mixedPairEditBoxDAO:SetText("5")

sidebetMixedPair1TitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sidebetMixedPair1TitleTextDAO:SetPoint("TOPLEFT", 175, -38)
sidebetMixedPair1TitleTextDAO:SetText(":1")
sidebetMixedPair1TitleTextDAO:SetJustifyH("LEFT")
sidebetMixedPair1TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 13, "OUTLINE")

sidebetColouredPairTitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sidebetColouredPairTitleTextDAO:SetPoint("TOPLEFT", 13, -58)
sidebetColouredPairTitleTextDAO:SetText("Coloured Pair")
sidebetColouredPairTitleTextDAO:SetJustifyH("LEFT")
sidebetColouredPairTitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Edit Box for Coloured Pair
colouredPairEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame3DAO, "InputBoxTemplate")
colouredPairEditBoxDAO:SetSize(28, 15)
colouredPairEditBoxDAO:SetPoint("TOPRIGHT", controlPanelFrame3DAO, -27, -55)
colouredPairEditBoxDAO:SetAutoFocus(false)
colouredPairEditBoxDAO:SetText("10")

colouredMixedPair1TitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
colouredMixedPair1TitleTextDAO:SetPoint("TOPLEFT", 175, -56)
colouredMixedPair1TitleTextDAO:SetText(":1")
colouredMixedPair1TitleTextDAO:SetJustifyH("LEFT")
colouredMixedPair1TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 13, "OUTLINE")

sidebetPerfectPairTitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sidebetPerfectPairTitleTextDAO:SetPoint("TOPLEFT", 13, -76)
sidebetPerfectPairTitleTextDAO:SetText("Perfect Pair")
sidebetPerfectPairTitleTextDAO:SetJustifyH("LEFT")
sidebetPerfectPairTitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

sidebetDividerLineTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sidebetDividerLineTextDAO:SetPoint("TOPLEFT", 14, -84)
sidebetDividerLineTextDAO:SetText("___________________")
sidebetDividerLineTextDAO:SetJustifyH("LEFT")
sidebetDividerLineTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")

-- Edit Box for Perfect Pair
perfectPairEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame3DAO, "InputBoxTemplate")
perfectPairEditBoxDAO:SetSize(28, 15)
perfectPairEditBoxDAO:SetPoint("TOPRIGHT", controlPanelFrame3DAO, -27, -73)
perfectPairEditBoxDAO:SetAutoFocus(false)
perfectPairEditBoxDAO:SetText("25")

perfectMixedPair1TitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
perfectMixedPair1TitleTextDAO:SetPoint("TOPLEFT", 175, -75)
perfectMixedPair1TitleTextDAO:SetText(":1")
perfectMixedPair1TitleTextDAO:SetJustifyH("LEFT")
perfectMixedPair1TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 13, "OUTLINE")

sidebetFlushTitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sidebetFlushTitleTextDAO:SetPoint("TOPLEFT", 13, -112)
sidebetFlushTitleTextDAO:SetText("Flush")
sidebetFlushTitleTextDAO:SetJustifyH("LEFT")
sidebetFlushTitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Edit Box for Flush
flushEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame3DAO, "InputBoxTemplate")
flushEditBoxDAO:SetSize(28, 15)
flushEditBoxDAO:SetPoint("TOPRIGHT", controlPanelFrame3DAO, -27, -109)
flushEditBoxDAO:SetAutoFocus(false)
flushEditBoxDAO:SetText("5")

flush1TitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
flush1TitleTextDAO:SetPoint("TOPLEFT", 175, -111)
flush1TitleTextDAO:SetText(":1")
flush1TitleTextDAO:SetJustifyH("LEFT")
flush1TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 13, "OUTLINE")
-----------------------

sidebetStraightTitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sidebetStraightTitleTextDAO:SetPoint("TOPLEFT", 13, -130)
sidebetStraightTitleTextDAO:SetText("Straight")
sidebetStraightTitleTextDAO:SetJustifyH("LEFT")
sidebetStraightTitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Edit Box for Straight
straightEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame3DAO, "InputBoxTemplate")
straightEditBoxDAO:SetSize(28, 15)
straightEditBoxDAO:SetPoint("TOPRIGHT", controlPanelFrame3DAO, -27, -127)
straightEditBoxDAO:SetAutoFocus(false)
straightEditBoxDAO:SetText("10")

straight1TitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
straight1TitleTextDAO:SetPoint("TOPLEFT", 175, -129)
straight1TitleTextDAO:SetText(":1")
straight1TitleTextDAO:SetJustifyH("LEFT")
straight1TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 13, "OUTLINE")
-----------------------

sidebetThreeOfAKindTitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sidebetThreeOfAKindTitleTextDAO:SetPoint("TOPLEFT", 13, -148)
sidebetThreeOfAKindTitleTextDAO:SetText("Three of a Kind")
sidebetThreeOfAKindTitleTextDAO:SetJustifyH("LEFT")
sidebetThreeOfAKindTitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Edit Box for Three of a Kind
threeOfAKindEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame3DAO, "InputBoxTemplate")
threeOfAKindEditBoxDAO:SetSize(28, 15)
threeOfAKindEditBoxDAO:SetPoint("TOPRIGHT", controlPanelFrame3DAO, -27, -145)
threeOfAKindEditBoxDAO:SetAutoFocus(false)
threeOfAKindEditBoxDAO:SetText("25")

threeOfAKind1TitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
threeOfAKind1TitleTextDAO:SetPoint("TOPLEFT", 175, -147)
threeOfAKind1TitleTextDAO:SetText(":1")
threeOfAKind1TitleTextDAO:SetJustifyH("LEFT")
threeOfAKind1TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 13, "OUTLINE")
-----------------------

sidebetStraightFlushTitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sidebetStraightFlushTitleTextDAO:SetPoint("TOPLEFT", 13, -166)
sidebetStraightFlushTitleTextDAO:SetText("Straight Flush")
sidebetStraightFlushTitleTextDAO:SetJustifyH("LEFT")
sidebetStraightFlushTitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Edit Box for Straight Flush
straightFlushEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame3DAO, "InputBoxTemplate")
straightFlushEditBoxDAO:SetSize(28, 15)
straightFlushEditBoxDAO:SetPoint("TOPRIGHT", controlPanelFrame3DAO, -27, -163)
straightFlushEditBoxDAO:SetAutoFocus(false)
straightFlushEditBoxDAO:SetText("40")

straightFlush1TitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
straightFlush1TitleTextDAO:SetPoint("TOPLEFT", 175, -165)
straightFlush1TitleTextDAO:SetText(":1")
straightFlush1TitleTextDAO:SetJustifyH("LEFT")
straightFlush1TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 13, "OUTLINE")
-----------------------

sidebetSuitedThreeOfAKindTitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
sidebetSuitedThreeOfAKindTitleTextDAO:SetPoint("TOPLEFT", 13, -184)
sidebetSuitedThreeOfAKindTitleTextDAO:SetText("Suited Three of a Kind")
sidebetSuitedThreeOfAKindTitleTextDAO:SetJustifyH("LEFT")
sidebetSuitedThreeOfAKindTitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Edit Box for Suited Three of a Kind
suitedThreeOfAKindEditBoxDAO = CreateFrame("EditBox", nil, controlPanelFrame3DAO, "InputBoxTemplate")
suitedThreeOfAKindEditBoxDAO:SetSize(28, 15)
suitedThreeOfAKindEditBoxDAO:SetPoint("TOPRIGHT", controlPanelFrame3DAO, -27, -181)
suitedThreeOfAKindEditBoxDAO:SetAutoFocus(false)
suitedThreeOfAKindEditBoxDAO:SetText("100")

suitedThreeOfAKind1TitleTextDAO = controlPanelFrame3DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
suitedThreeOfAKind1TitleTextDAO:SetPoint("TOPLEFT", 175, -183)
suitedThreeOfAKind1TitleTextDAO:SetText(":1")
suitedThreeOfAKind1TitleTextDAO:SetJustifyH("LEFT")
suitedThreeOfAKind1TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 13, "OUTLINE")
-----------------------

-- "Set Payouts" buttonDAO which updates the payouts
controlPanelFrame3DAO.setPayoutsButtonDAO = CreateFrame("Button", nil, controlPanelFrame3DAO, "GameMenuButtonTemplate")
controlPanelFrame3DAO.setPayoutsButtonDAO:SetPoint("BOTTOM", controlPanelFrame3DAO, 0, 10)
controlPanelFrame3DAO.setPayoutsButtonDAO:SetSize(83, 25)
controlPanelFrame3DAO.setPayoutsButtonDAO:SetText("Set Payouts")
controlPanelFrame3DAO.setPayoutsButtonDAO:SetNormalFontObject("GameFontWhiteSmall")
controlPanelFrame3DAO.setPayoutsButtonDAO:SetHighlightFontObject("GameFontWhiteSmall")

controlPanelFrame3DAO:SetScript("OnMouseDown", function(selfDAO, buttonDAO)
    if buttonDAO == "LeftButton" then
        minMainBetEditBoxDAO:ClearFocus()
        maxMainBetEditBoxDAO:ClearFocus()
        minSideBetEditBoxDAO:ClearFocus()
        maxSideBetEditBoxDAO:ClearFocus()
        mixedPairEditBoxDAO:ClearFocus()
        colouredPairEditBoxDAO:ClearFocus()
        perfectPairEditBoxDAO:ClearFocus()
        flushEditBoxDAO:ClearFocus()
        straightEditBoxDAO:ClearFocus()
        threeOfAKindEditBoxDAO:ClearFocus()
        straightFlushEditBoxDAO:ClearFocus()
        suitedThreeOfAKindEditBoxDAO:ClearFocus()
    end
end)





-- Creating the controlPanelFrame4DAO window
controlPanelFrame4DAO = CreateFrame("Frame", "ControlPanelFrame", UIParent, "InsetFrameTemplate")
controlPanelFrame4DAO:SetSize(200, 100)
controlPanelFrame4DAO:SetPoint("BOTTOM", controlPanelFrame2DAO, 0, -100)
controlPanelFrame4DAO:SetFrameStrata("HIGH")
controlPanelFrame4DAO:SetFrameLevel(controlPanelFrame4DAO:GetFrameLevel() + 105)
controlPanelFrame4DAO:SetAlpha(0.93)
controlPanelFrame4DAO:Hide()

betControlTextDAO = controlPanelFrame4DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
betControlTextDAO:SetPoint("TOP", 0, -12)
betControlTextDAO:SetText("Bet Lock Control")

betSubtitleTextDAO = controlPanelFrame4DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
betSubtitleTextDAO:SetPoint("TOP", 0, -65)
betSubtitleTextDAO:SetText("Lock player bets BEFORE changing\nany of the table settings above!")
betSubtitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Lock Bets checkbox
lockBetsCheckboxDAO = CreateFrame("CheckButton", "lockBetsCheckboxDAO", controlPanelFrame4DAO, "UICheckButtonTemplate")
lockBetsCheckboxDAO:SetPoint("TOPLEFT", 15, -30)

playersCanPlaceBetsTextDAO = controlPanelFrame4DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
playersCanPlaceBetsTextDAO:SetPoint("TOPLEFT", 50, -40)
playersCanPlaceBetsTextDAO:SetJustifyH("LEFT")
playersCanPlaceBetsTextDAO:SetText("Players Can Place Bets")
playersCanPlaceBetsTextDAO:SetTextColor(0.341, 0.929, 0.459)
playersCanPlaceBetsTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

playersCannotPlaceBetsTextDAO = controlPanelFrame4DAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
playersCannotPlaceBetsTextDAO:SetPoint("TOPLEFT", 50, -40)
playersCannotPlaceBetsTextDAO:SetJustifyH("LEFT")
playersCannotPlaceBetsTextDAO:SetText("Players Cannot Place Bets")
playersCannotPlaceBetsTextDAO:SetTextColor(0.988, 0.443, 0.443)
playersCannotPlaceBetsTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")
playersCannotPlaceBetsTextDAO:Hide()

-- Function to handle checkbox state change
local function OnCheckboxStateChangedDAO(selfDAO)
    local isCheckedDAO = selfDAO:GetChecked()

    if isCheckedDAO then
        SendChatMessage("{diamond} The Dealer has locked the table - please wait.", "RAID")
        playersCannotPlaceBetsTextDAO:Show()
        playersCanPlaceBetsTextDAO:Hide()
    else
        SendChatMessage("{diamond} The Dealer has unlocked the table - you're now able to place a bet.", "RAID")
        playersCannotPlaceBetsTextDAO:Hide()
        playersCanPlaceBetsTextDAO:Show()
    end
end

-- Set the script to handle checkbox state change
lockBetsCheckboxDAO:SetScript("OnClick", OnCheckboxStateChangedDAO)





















-- Creating the tableLimits window
tableLimitsFrameDAO = CreateFrame("Frame", "TableLimitsPanelFrame", UIParent, "InsetFrameTemplate")
tableLimitsFrameDAO:SetSize(197, 46)
tableLimitsFrameDAO:SetPoint("BOTTOMLEFT", dealerFrameDAO, 95, 12)
tableLimitsFrameDAO:SetAlpha(0.6)
tableLimitsFrameDAO:SetFrameStrata("TOOLTIP")
tableLimitsFrameDAO:Hide()

-- Creating the tableLimits window
tableLimitsTitleFrameDAO = CreateFrame("Frame", "TableLimitsPanelFrame", UIParent, "InsetFrameTemplate")
tableLimitsTitleFrameDAO:SetSize(197, 16)
tableLimitsTitleFrameDAO:SetPoint("TOP", tableLimitsFrameDAO, 0, 0)
tableLimitsTitleFrameDAO:SetFrameStrata("TOOLTIP")
tableLimitsTitleFrameDAO:Hide()

tableLimitsTextFrameDAO = CreateFrame("Frame", nil, UIParent)
tableLimitsTextFrameDAO:SetAllPoints(tableLimitsFrameDAO)
tableLimitsTextFrameDAO:SetFrameStrata("TOOLTIP")
tableLimitsTextFrameDAO:Hide()

tableLimitsTextTitleDAO = tableLimitsTextFrameDAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
tableLimitsTextTitleDAO:SetPoint("TOP", 0, -4)
tableLimitsTextTitleDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
tableLimitsTextTitleDAO:SetText("Table Limits")

tableLimitsMainTitleDAO = tableLimitsTextFrameDAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
tableLimitsMainTitleDAO:SetPoint("TOPLEFT", 40, -20)
tableLimitsMainTitleDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
tableLimitsMainTitleDAO:SetText("Main:")

tableLimitsMainTextDAO = tableLimitsTextFrameDAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
tableLimitsMainTextDAO:SetPoint("TOPLEFT", 80, -20)
tableLimitsMainTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
tableLimitsMainTextDAO:SetJustifyH("LEFT")
tableLimitsMainTextDAO:SetText("1000G  -  25000G")
tableLimitsMainTextDAO:SetTextColor(1, 0.992, 0.506)

tableLimitsSideTitleDAO = tableLimitsTextFrameDAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
tableLimitsSideTitleDAO:SetPoint("TOPLEFT", 44, -31)
tableLimitsSideTitleDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
tableLimitsSideTitleDAO:SetText("Side:")

tableLimitsSideTextDAO = tableLimitsTextFrameDAO:CreateFontString(nil, "ARTWORK", "GameFontHighlight")
tableLimitsSideTextDAO:SetPoint("TOPLEFT", 80, -31)
tableLimitsSideTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
tableLimitsSideTextDAO:SetJustifyH("LEFT")
tableLimitsSideTextDAO:SetText("100G  -  2500G")
tableLimitsSideTextDAO:SetTextColor(1, 0.992, 0.506)



















-- Creating the bankingFrameDAO window
bankingFrameDAO = CreateFrame("Frame", "BlackjackDealerFrame", UIParent, "InsetFrameTemplate")
bankingFrameDAO:SetSize(253, 515)
bankingFrameDAO:SetPoint("LEFT", dealerFrameDAO, -254, 0)
bankingFrameDAO:SetFrameStrata("HIGH")
bankingFrameDAO:SetFrameLevel(bankingFrameDAO:GetFrameLevel() + 100)
bankingFrameDAO:Hide()

-- Player 1 Title Text
bankingFrameDAO.player1TitleDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1TitleDAO:SetPoint("TOPLEFT", bankingFrameDAO, 50, -21)
bankingFrameDAO.player1TitleDAO:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
bankingFrameDAO.player1TitleDAO:SetJustifyH("LEFT")
bankingFrameDAO.player1TitleDAO:SetTextColor(1, 0.98, 0.557)
bankingFrameDAO.player1TitleDAO:SetText("Player 1 - Seat Empty")

-- Player 1 "Total Wagered" Text
bankingFrameDAO.player1totalWageredTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1totalWageredTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -43)
bankingFrameDAO.player1totalWageredTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player1totalWageredTextDAO:SetText("Total Wagered:")
bankingFrameDAO.player1totalWageredTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 1 "Total Won" Text
bankingFrameDAO.player1totalWonTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1totalWonTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -55)
bankingFrameDAO.player1totalWonTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player1totalWonTextDAO:SetText("Total Won:")
bankingFrameDAO.player1totalWonTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 1 "Total Lost" Text
bankingFrameDAO.player1totalLostTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1totalLostTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -67)
bankingFrameDAO.player1totalLostTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player1totalLostTextDAO:SetText("Total Lost:")
bankingFrameDAO.player1totalLostTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 1 "Total Profit" Text
bankingFrameDAO.player1totalProfitTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1totalProfitTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -79)
bankingFrameDAO.player1totalProfitTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player1totalProfitTextDAO:SetText("Total Profit:")
bankingFrameDAO.player1totalProfitTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 1 "Bankroll" Text
bankingFrameDAO.player1BankrollTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1BankrollTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -91)
bankingFrameDAO.player1BankrollTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player1BankrollTextDAO:SetText("Bankroll:")
bankingFrameDAO.player1BankrollTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 1 Amounts Text
bankingFrameDAO.player1totalWageredAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1totalWageredAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -43)
bankingFrameDAO.player1totalWageredAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player1totalWageredAmountDAO:SetText("0 G")
bankingFrameDAO.player1totalWageredAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player1totalWonAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1totalWonAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -55)
bankingFrameDAO.player1totalWonAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player1totalWonAmountDAO:SetText("0 G")
bankingFrameDAO.player1totalWonAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player1totalLostAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1totalLostAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -67)
bankingFrameDAO.player1totalLostAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player1totalLostAmountDAO:SetText("0 G")
bankingFrameDAO.player1totalLostAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player1totalProfitAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1totalProfitAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -79)
bankingFrameDAO.player1totalProfitAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player1totalProfitAmountDAO:SetText("0 G")
bankingFrameDAO.player1totalProfitAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player1BankrollAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1BankrollAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -91)
bankingFrameDAO.player1BankrollAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player1BankrollAmountDAO:SetText("0 G")
bankingFrameDAO.player1BankrollAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Title for Player 1 bankrollDAO
bankingFrameDAO.player1BuyInAmountTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player1BuyInAmountTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 185, -43)
bankingFrameDAO.player1BuyInAmountTextDAO:SetJustifyH("CENTER")
bankingFrameDAO.player1BuyInAmountTextDAO:SetText("Amount")
bankingFrameDAO.player1BuyInAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Edit Box for Player 1 bankrollDAO
player1BankrollEditBoxDAO = CreateFrame("EditBox", nil, bankingFrameDAO, "InputBoxTemplate")
player1BankrollEditBoxDAO:SetSize(44, 31)
player1BankrollEditBoxDAO:SetPoint("TOPLEFT", bankingFrameDAO, 187, -49)
player1BankrollEditBoxDAO:SetAutoFocus(false)

-- "Kick" buttonDAO for Player 1 bankrollDAO
bankingFrameDAO.player1KickButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player1KickButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -17)
bankingFrameDAO.player1KickButtonDAO:SetSize(21, 20)
bankingFrameDAO.player1KickButtonDAO:SetText("X")
bankingFrameDAO.player1KickButtonDAO:SetNormalFontObject("GameFontRedSmall")
bankingFrameDAO.player1KickButtonDAO:SetHighlightFontObject("GameFontRedSmall")

-- "Add" buttonDAO for Player 1 bankrollDAO
bankingFrameDAO.player1AddButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player1AddButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 181, -78)
bankingFrameDAO.player1AddButtonDAO:SetSize(25, 23)
bankingFrameDAO.player1AddButtonDAO:SetText("+")
bankingFrameDAO.player1AddButtonDAO:SetNormalFontObject("GameFontGreen")
bankingFrameDAO.player1AddButtonDAO:SetHighlightFontObject("GameFontGreen")

-- "Remove" buttonDAO for Player 1 bankrollDAO
bankingFrameDAO.player1RemoveButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player1RemoveButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 207, -78)
bankingFrameDAO.player1RemoveButtonDAO:SetSize(25, 23)
bankingFrameDAO.player1RemoveButtonDAO:SetText("-")
bankingFrameDAO.player1RemoveButtonDAO:SetNormalFontObject("GameFontRedLarge")
bankingFrameDAO.player1RemoveButtonDAO:SetHighlightFontObject("GameFontRedLarge")








-- Player 2 Title Text
bankingFrameDAO.player2TitleDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2TitleDAO:SetPoint("TOPLEFT", bankingFrameDAO, 50, -121)
bankingFrameDAO.player2TitleDAO:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
bankingFrameDAO.player2TitleDAO:SetJustifyH("LEFT")
bankingFrameDAO.player2TitleDAO:SetTextColor(1, 0.98, 0.557)
bankingFrameDAO.player2TitleDAO:SetText("Player 2 - Seat Empty")

-- Player 2 "Total Wagered" Text
bankingFrameDAO.player2totalWageredTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2totalWageredTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -141)
bankingFrameDAO.player2totalWageredTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player2totalWageredTextDAO:SetText("Total Wagered:")
bankingFrameDAO.player2totalWageredTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 2 "Total Won" Text
bankingFrameDAO.player2totalWonTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2totalWonTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -152)
bankingFrameDAO.player2totalWonTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player2totalWonTextDAO:SetText("Total Won:")
bankingFrameDAO.player2totalWonTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 2 "Total Lost" Text
bankingFrameDAO.player2totalLostTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2totalLostTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -165)
bankingFrameDAO.player2totalLostTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player2totalLostTextDAO:SetText("Total Lost:")
bankingFrameDAO.player2totalLostTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 2 "Total Profit" Text
bankingFrameDAO.player2totalProfitTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2totalProfitTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -177)
bankingFrameDAO.player2totalProfitTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player2totalProfitTextDAO:SetText("Total Profit:")
bankingFrameDAO.player2totalProfitTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 2 "Bankroll" Text
bankingFrameDAO.player2BankrollTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2BankrollTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -189)
bankingFrameDAO.player2BankrollTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player2BankrollTextDAO:SetText("Bankroll:")
bankingFrameDAO.player2BankrollTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 2 Amounts Text
bankingFrameDAO.player2totalWageredAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2totalWageredAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -141)
bankingFrameDAO.player2totalWageredAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player2totalWageredAmountDAO:SetText("0 G")
bankingFrameDAO.player2totalWageredAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player2totalWonAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2totalWonAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -152)
bankingFrameDAO.player2totalWonAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player2totalWonAmountDAO:SetText("0 G")
bankingFrameDAO.player2totalWonAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player2totalLostAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2totalLostAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -165)
bankingFrameDAO.player2totalLostAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player2totalLostAmountDAO:SetText("0 G")
bankingFrameDAO.player2totalLostAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player2totalProfitAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2totalProfitAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -177)
bankingFrameDAO.player2totalProfitAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player2totalProfitAmountDAO:SetText("0 G")
bankingFrameDAO.player2totalProfitAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player2BankrollAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2BankrollAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -189)
bankingFrameDAO.player2BankrollAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player2BankrollAmountDAO:SetText("0 G")
bankingFrameDAO.player2BankrollAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Title for Player 2 bankrollDAO
bankingFrameDAO.player2BuyInAmountTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player2BuyInAmountTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 185, -141)
bankingFrameDAO.player2BuyInAmountTextDAO:SetJustifyH("CENTER")
bankingFrameDAO.player2BuyInAmountTextDAO:SetText("Amount")
bankingFrameDAO.player2BuyInAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Edit Box for Player 2 bankrollDAO
player2BankrollEditBoxDAO = CreateFrame("EditBox", nil, bankingFrameDAO, "InputBoxTemplate")
player2BankrollEditBoxDAO:SetSize(44, 31)
player2BankrollEditBoxDAO:SetPoint("TOPLEFT", bankingFrameDAO, 187, -147)
player2BankrollEditBoxDAO:SetAutoFocus(false)

-- "Kick" buttonDAO for Player 1 bankrollDAO
bankingFrameDAO.player2KickButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player2KickButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -117)
bankingFrameDAO.player2KickButtonDAO:SetSize(21, 20)
bankingFrameDAO.player2KickButtonDAO:SetText("X")
bankingFrameDAO.player2KickButtonDAO:SetNormalFontObject("GameFontRedSmall")
bankingFrameDAO.player2KickButtonDAO:SetHighlightFontObject("GameFontRedSmall")

-- "Add" buttonDAO for Player 2 bankrollDAO
bankingFrameDAO.player2AddButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player2AddButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 181, -176)
bankingFrameDAO.player2AddButtonDAO:SetSize(25, 23)
bankingFrameDAO.player2AddButtonDAO:SetText("+")
bankingFrameDAO.player2AddButtonDAO:SetNormalFontObject("GameFontGreen")
bankingFrameDAO.player2AddButtonDAO:SetHighlightFontObject("GameFontGreen")

-- "Remove" buttonDAO for Player 2 bankrollDAO
bankingFrameDAO.player2RemoveButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player2RemoveButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 207, -176)
bankingFrameDAO.player2RemoveButtonDAO:SetSize(25, 23)
bankingFrameDAO.player2RemoveButtonDAO:SetText("-")
bankingFrameDAO.player2RemoveButtonDAO:SetNormalFontObject("GameFontRedLarge")
bankingFrameDAO.player2RemoveButtonDAO:SetHighlightFontObject("GameFontRedLarge")




-- Player 3 Title Text
bankingFrameDAO.player3TitleDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3TitleDAO:SetPoint("TOPLEFT", bankingFrameDAO, 50, -217)
bankingFrameDAO.player3TitleDAO:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
bankingFrameDAO.player3TitleDAO:SetJustifyH("LEFT")
bankingFrameDAO.player3TitleDAO:SetTextColor(1, 0.98, 0.557)
bankingFrameDAO.player3TitleDAO:SetText("Player 3 - Seat Empty")

-- Player 3 "Total Wagered" Text
bankingFrameDAO.player3totalWageredTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3totalWageredTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -239)
bankingFrameDAO.player3totalWageredTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player3totalWageredTextDAO:SetText("Total Wagered:")
bankingFrameDAO.player3totalWageredTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 3 "Total Won" Text
bankingFrameDAO.player3totalWonTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3totalWonTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -251)
bankingFrameDAO.player3totalWonTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player3totalWonTextDAO:SetText("Total Won:")
bankingFrameDAO.player3totalWonTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 3 "Total Lost" Text
bankingFrameDAO.player3totalLostTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3totalLostTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -263)
bankingFrameDAO.player3totalLostTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player3totalLostTextDAO:SetText("Total Lost:")
bankingFrameDAO.player3totalLostTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 3 "Total Profit" Text
bankingFrameDAO.player3totalProfitTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3totalProfitTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -275)
bankingFrameDAO.player3totalProfitTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player3totalProfitTextDAO:SetText("Total Profit:")
bankingFrameDAO.player3totalProfitTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 3 "Bankroll" Text
bankingFrameDAO.player3BankrollTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3BankrollTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -287)
bankingFrameDAO.player3BankrollTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player3BankrollTextDAO:SetText("Bankroll:")
bankingFrameDAO.player3BankrollTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 3 Amounts Text
bankingFrameDAO.player3totalWageredAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3totalWageredAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -239)
bankingFrameDAO.player3totalWageredAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player3totalWageredAmountDAO:SetText("0 G")
bankingFrameDAO.player3totalWageredAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player3totalWonAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3totalWonAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -251)
bankingFrameDAO.player3totalWonAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player3totalWonAmountDAO:SetText("0 G")
bankingFrameDAO.player3totalWonAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player3totalLostAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3totalLostAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -263)
bankingFrameDAO.player3totalLostAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player3totalLostAmountDAO:SetText("0 G")
bankingFrameDAO.player3totalLostAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player3totalProfitAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3totalProfitAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -275)
bankingFrameDAO.player3totalProfitAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player3totalProfitAmountDAO:SetText("0 G")
bankingFrameDAO.player3totalProfitAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player3BankrollAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3BankrollAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -287)
bankingFrameDAO.player3BankrollAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player3BankrollAmountDAO:SetText("0 G")
bankingFrameDAO.player3BankrollAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Title for Player 3 bankrollDAO
bankingFrameDAO.player3BuyInAmountTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player3BuyInAmountTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 185, -239)
bankingFrameDAO.player3BuyInAmountTextDAO:SetJustifyH("CENTER")
bankingFrameDAO.player3BuyInAmountTextDAO:SetText("Amount")
bankingFrameDAO.player3BuyInAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Edit Box for Player 3 bankrollDAO
player3BankrollEditBoxDAO = CreateFrame("EditBox", nil, bankingFrameDAO, "InputBoxTemplate")
player3BankrollEditBoxDAO:SetSize(44, 31)
player3BankrollEditBoxDAO:SetPoint("TOPLEFT", bankingFrameDAO, 187, -245)
player3BankrollEditBoxDAO:SetAutoFocus(false)

-- "Kick" buttonDAO for Player 1 bankrollDAO
bankingFrameDAO.player3KickButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player3KickButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -214)
bankingFrameDAO.player3KickButtonDAO:SetSize(21, 20)
bankingFrameDAO.player3KickButtonDAO:SetText("X")
bankingFrameDAO.player3KickButtonDAO:SetNormalFontObject("GameFontRedSmall")
bankingFrameDAO.player3KickButtonDAO:SetHighlightFontObject("GameFontRedSmall")

-- "Add" buttonDAO for Player 3 bankrollDAO
bankingFrameDAO.player3AddButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player3AddButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 181, -274)
bankingFrameDAO.player3AddButtonDAO:SetSize(25, 23)
bankingFrameDAO.player3AddButtonDAO:SetText("+")
bankingFrameDAO.player3AddButtonDAO:SetNormalFontObject("GameFontGreen")
bankingFrameDAO.player3AddButtonDAO:SetHighlightFontObject("GameFontGreen")

-- "Remove" buttonDAO for Player 3 bankrollDAO
bankingFrameDAO.player3RemoveButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player3RemoveButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 207, -274)
bankingFrameDAO.player3RemoveButtonDAO:SetSize(25, 23)
bankingFrameDAO.player3RemoveButtonDAO:SetText("-")
bankingFrameDAO.player3RemoveButtonDAO:SetNormalFontObject("GameFontRedLarge")
bankingFrameDAO.player3RemoveButtonDAO:SetHighlightFontObject("GameFontRedLarge")





-- Player 4 Title Text
bankingFrameDAO.player4TitleDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4TitleDAO:SetPoint("TOPLEFT", bankingFrameDAO, 50, -315)
bankingFrameDAO.player4TitleDAO:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
bankingFrameDAO.player4TitleDAO:SetJustifyH("LEFT")
bankingFrameDAO.player4TitleDAO:SetTextColor(1, 0.98, 0.557)
bankingFrameDAO.player4TitleDAO:SetText("Player 4 - Seat Empty")

-- Player 4 "Total Wagered" Text
bankingFrameDAO.player4totalWageredTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4totalWageredTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -337)
bankingFrameDAO.player4totalWageredTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player4totalWageredTextDAO:SetText("Total Wagered:")
bankingFrameDAO.player4totalWageredTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 4 "Total Won" Text
bankingFrameDAO.player4totalWonTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4totalWonTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -349)
bankingFrameDAO.player4totalWonTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player4totalWonTextDAO:SetText("Total Won:")
bankingFrameDAO.player4totalWonTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 4 "Total Lost" Text
bankingFrameDAO.player4totalLostTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4totalLostTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -361)
bankingFrameDAO.player4totalLostTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player4totalLostTextDAO:SetText("Total Lost:")
bankingFrameDAO.player4totalLostTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 4 "Total Profit" Text
bankingFrameDAO.player4totalProfitTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4totalProfitTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -373)
bankingFrameDAO.player4totalProfitTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player4totalProfitTextDAO:SetText("Total Profit:")
bankingFrameDAO.player4totalProfitTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 4 "Bankroll" Text
bankingFrameDAO.player4BankrollTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4BankrollTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -385)
bankingFrameDAO.player4BankrollTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player4BankrollTextDAO:SetText("Bankroll:")
bankingFrameDAO.player4BankrollTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 4 Amounts Text
bankingFrameDAO.player4totalWageredAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4totalWageredAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -337)
bankingFrameDAO.player4totalWageredAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player4totalWageredAmountDAO:SetText("0 G")
bankingFrameDAO.player4totalWageredAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player4totalWonAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4totalWonAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -349)
bankingFrameDAO.player4totalWonAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player4totalWonAmountDAO:SetText("0 G")
bankingFrameDAO.player4totalWonAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player4totalLostAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4totalLostAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -361)
bankingFrameDAO.player4totalLostAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player4totalLostAmountDAO:SetText("0 G")
bankingFrameDAO.player4totalLostAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player4totalProfitAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4totalProfitAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -373)
bankingFrameDAO.player4totalProfitAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player4totalProfitAmountDAO:SetText("0 G")
bankingFrameDAO.player4totalProfitAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player4BankrollAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4BankrollAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -385)
bankingFrameDAO.player4BankrollAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player4BankrollAmountDAO:SetText("0 G")
bankingFrameDAO.player4BankrollAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Title for Player 4 bankrollDAO
bankingFrameDAO.player4BuyInAmountTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player4BuyInAmountTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 185, -337)
bankingFrameDAO.player4BuyInAmountTextDAO:SetJustifyH("CENTER")
bankingFrameDAO.player4BuyInAmountTextDAO:SetText("Amount")
bankingFrameDAO.player4BuyInAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Edit Box for Player 4 bankrollDAO
player4BankrollEditBoxDAO = CreateFrame("EditBox", nil, bankingFrameDAO, "InputBoxTemplate")
player4BankrollEditBoxDAO:SetSize(44, 31)
player4BankrollEditBoxDAO:SetPoint("TOPLEFT", bankingFrameDAO, 187, -343)
player4BankrollEditBoxDAO:SetAutoFocus(false)

-- "Kick" buttonDAO for Player 1 bankrollDAO
bankingFrameDAO.player4KickButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player4KickButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -312)
bankingFrameDAO.player4KickButtonDAO:SetSize(21, 20)
bankingFrameDAO.player4KickButtonDAO:SetText("X")
bankingFrameDAO.player4KickButtonDAO:SetNormalFontObject("GameFontRedSmall")
bankingFrameDAO.player4KickButtonDAO:SetHighlightFontObject("GameFontRedSmall")

-- "Add" buttonDAO for Player 4 bankrollDAO
bankingFrameDAO.player4AddButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player4AddButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 181, -372)
bankingFrameDAO.player4AddButtonDAO:SetSize(25, 23)
bankingFrameDAO.player4AddButtonDAO:SetText("+")
bankingFrameDAO.player4AddButtonDAO:SetNormalFontObject("GameFontGreen")
bankingFrameDAO.player4AddButtonDAO:SetHighlightFontObject("GameFontGreen")

-- "Remove" buttonDAO for Player 4 bankrollDAO
bankingFrameDAO.player4RemoveButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player4RemoveButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 207, -372)
bankingFrameDAO.player4RemoveButtonDAO:SetSize(25, 23)
bankingFrameDAO.player4RemoveButtonDAO:SetText("-")
bankingFrameDAO.player4RemoveButtonDAO:SetNormalFontObject("GameFontRedLarge")
bankingFrameDAO.player4RemoveButtonDAO:SetHighlightFontObject("GameFontRedLarge")





-- Player 5 Title Text
bankingFrameDAO.player5TitleDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5TitleDAO:SetPoint("TOPLEFT", bankingFrameDAO, 50, -413)
bankingFrameDAO.player5TitleDAO:SetFont("Fonts\\FRIZQT__.TTF", 14, "OUTLINE")
bankingFrameDAO.player5TitleDAO:SetJustifyH("LEFT")
bankingFrameDAO.player5TitleDAO:SetTextColor(1, 0.98, 0.557)
bankingFrameDAO.player5TitleDAO:SetText("Player 5 - Seat Empty")

-- Player 5 "Total Wagered" Text
bankingFrameDAO.player5totalWageredTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5totalWageredTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -435)
bankingFrameDAO.player5totalWageredTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player5totalWageredTextDAO:SetText("Total Wagered:")
bankingFrameDAO.player5totalWageredTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 5 "Total Won" Text
bankingFrameDAO.player5totalWonTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5totalWonTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -447)
bankingFrameDAO.player5totalWonTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player5totalWonTextDAO:SetText("Total Won:")
bankingFrameDAO.player5totalWonTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 5 "Total Lost" Text
bankingFrameDAO.player5totalLostTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5totalLostTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -459)
bankingFrameDAO.player5totalLostTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player5totalLostTextDAO:SetText("Total Lost:")
bankingFrameDAO.player5totalLostTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 5 "Total Profit" Text
bankingFrameDAO.player5totalProfitTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5totalProfitTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -471)
bankingFrameDAO.player5totalProfitTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player5totalProfitTextDAO:SetText("Total Profit:")
bankingFrameDAO.player5totalProfitTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 5 "Bankroll" Text
bankingFrameDAO.player5BankrollTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5BankrollTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -483)
bankingFrameDAO.player5BankrollTextDAO:SetJustifyH("LEFT")
bankingFrameDAO.player5BankrollTextDAO:SetText("Bankroll:")
bankingFrameDAO.player5BankrollTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Player 5 Amounts Text
bankingFrameDAO.player5totalWageredAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5totalWageredAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -435)
bankingFrameDAO.player5totalWageredAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player5totalWageredAmountDAO:SetText("0 G")
bankingFrameDAO.player5totalWageredAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player5totalWonAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5totalWonAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -447)
bankingFrameDAO.player5totalWonAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player5totalWonAmountDAO:SetText("0 G")
bankingFrameDAO.player5totalWonAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player5totalLostAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5totalLostAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -459)
bankingFrameDAO.player5totalLostAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player5totalLostAmountDAO:SetText("0 G")
bankingFrameDAO.player5totalLostAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player5totalProfitAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5totalProfitAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -471)
bankingFrameDAO.player5totalProfitAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player5totalProfitAmountDAO:SetText("0 G")
bankingFrameDAO.player5totalProfitAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

bankingFrameDAO.player5BankrollAmountDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5BankrollAmountDAO:SetPoint("TOPLEFT", bankingFrameDAO, 125, -483)
bankingFrameDAO.player5BankrollAmountDAO:SetJustifyH("LEFT")
bankingFrameDAO.player5BankrollAmountDAO:SetText("0 G")
bankingFrameDAO.player5BankrollAmountDAO:SetFont("Fonts\\FRIZQT__.TTF", 10, "OUTLINE")

-- Title for Player 5 bankrollDAO
bankingFrameDAO.player5BuyInAmountTextDAO = bankingFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
bankingFrameDAO.player5BuyInAmountTextDAO:SetPoint("TOPLEFT", bankingFrameDAO, 185, -435)
bankingFrameDAO.player5BuyInAmountTextDAO:SetJustifyH("CENTER")
bankingFrameDAO.player5BuyInAmountTextDAO:SetText("Amount")
bankingFrameDAO.player5BuyInAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")

-- Edit Box for Player 5 bankrollDAO
player5BankrollEditBoxDAO = CreateFrame("EditBox", nil, bankingFrameDAO, "InputBoxTemplate")
player5BankrollEditBoxDAO:SetSize(44, 31)
player5BankrollEditBoxDAO:SetPoint("TOPLEFT", bankingFrameDAO, 187, -441)
player5BankrollEditBoxDAO:SetAutoFocus(false)

-- "Kick" buttonDAO for Player 1 bankrollDAO
bankingFrameDAO.player5KickButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player5KickButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 25, -410)
bankingFrameDAO.player5KickButtonDAO:SetSize(21, 20)
bankingFrameDAO.player5KickButtonDAO:SetText("X")
bankingFrameDAO.player5KickButtonDAO:SetNormalFontObject("GameFontRedSmall")
bankingFrameDAO.player5KickButtonDAO:SetHighlightFontObject("GameFontRedSmall")

-- "Add" buttonDAO for Player 5 bankrollDAO
bankingFrameDAO.player5AddButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player5AddButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 181, -470)
bankingFrameDAO.player5AddButtonDAO:SetSize(25, 23)
bankingFrameDAO.player5AddButtonDAO:SetText("+")
bankingFrameDAO.player5AddButtonDAO:SetNormalFontObject("GameFontGreen")
bankingFrameDAO.player5AddButtonDAO:SetHighlightFontObject("GameFontGreen")

-- "Remove" buttonDAO for Player 5 bankrollDAO
bankingFrameDAO.player5RemoveButtonDAO = CreateFrame("Button", nil, bankingFrameDAO, "GameMenuButtonTemplate")
bankingFrameDAO.player5RemoveButtonDAO:SetPoint("TOPLEFT", bankingFrameDAO, 207, -470)
bankingFrameDAO.player5RemoveButtonDAO:SetSize(25, 23)
bankingFrameDAO.player5RemoveButtonDAO:SetText("-")
bankingFrameDAO.player5RemoveButtonDAO:SetNormalFontObject("GameFontRedLarge")
bankingFrameDAO.player5RemoveButtonDAO:SetHighlightFontObject("GameFontRedLarge")


bankingFrameDAO:SetScript("OnMouseDown", function(selfDAO, buttonDAO)
    if buttonDAO == "LeftButton" then
        player1BankrollEditBoxDAO:ClearFocus()
        player2BankrollEditBoxDAO:ClearFocus()
        player3BankrollEditBoxDAO:ClearFocus()
        player4BankrollEditBoxDAO:ClearFocus()
        player5BankrollEditBoxDAO:ClearFocus()
    end
end)

dealerFrameDAO:SetScript("OnMouseDown", function(selfDAO, buttonDAO)
    if buttonDAO == "LeftButton" then
        player1BankrollEditBoxDAO:ClearFocus()
        player2BankrollEditBoxDAO:ClearFocus()
        player3BankrollEditBoxDAO:ClearFocus()
        player4BankrollEditBoxDAO:ClearFocus()
        player5BankrollEditBoxDAO:ClearFocus()
    end
end)

dealerFrameDAO:SetScript("OnHide", function(selfDAO)
    bankingFrameDAO:Hide()
    tableLimitsFrameDAO:Hide()
    tableLimitsTitleFrameDAO:Hide()
    tableLimitsTextFrameDAO:Hide()
    controlPanelFrameDAO:Hide()
    controlPanelFrame2DAO:Hide()
    controlPanelFrame3DAO:Hide()
    controlPanelFrame4DAO:Hide()
end)

























-- >>> PLAYER 1 <<<
-- >>> PLAYER 1 <<<
-- >>> PLAYER 1 <<<

-- Bet Amounts
-- "Player 1" titleDAO
player1TitleTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player1TitleTextDAO:SetPoint("CENTER", dealerFrameDAO, -315, 80)
player1TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player1TitleTextDAO:SetJustifyH("CENTER")
player1TitleTextDAO:SetText("Player 1")
-- Player 1 character nameDAO
player1NameTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player1NameTextDAO:SetPoint("CENTER", dealerFrameDAO, -315, 62) -- Adjust the positioning as needed
player1NameTextDAO:SetText("Seat Empty")
player1NameTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
-- Player 1 "Main Bet" amount text
player1MainBetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player1MainBetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -315, 43)
player1MainBetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player1MainBetAmountTextDAO:SetJustifyH("CENTER")
player1MainBetAmountTextDAO:SetText("Main Bet: N/A")
player1MainBetAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 1 "Hand 1 Bet" amount text
player1Hand1BetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player1Hand1BetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -351, 43)
player1Hand1BetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player1Hand1BetAmountTextDAO:SetJustifyH("CENTER")
player1Hand1BetAmountTextDAO:SetText("H1: N/A")
player1Hand1BetAmountTextDAO:SetTextColor(1, 1, 1)
player1Hand1BetAmountTextDAO:Hide()
-- Player 1 "Hand 2 Bet" amount text
player1Hand2BetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player1Hand2BetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -279, 43)
player1Hand2BetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player1Hand2BetAmountTextDAO:SetJustifyH("CENTER")
player1Hand2BetAmountTextDAO:SetText("H2: N/A")
player1Hand2BetAmountTextDAO:SetTextColor(1, 1, 1)
player1Hand2BetAmountTextDAO:Hide()
-- Player 1 "Insurance Bet" amount text
player1InsuranceAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player1InsuranceAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -315, 32)
player1InsuranceAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player1InsuranceAmountTextDAO:SetJustifyH("CENTER")
player1InsuranceAmountTextDAO:SetText("Insurance: N/A")
player1InsuranceAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 1 "21+3 Side Bet" amount text
player1213AmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player1213AmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -315, 21)
player1213AmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player1213AmountTextDAO:SetJustifyH("CENTER")
player1213AmountTextDAO:SetText("21+3 Side Bet: N/A")
player1213AmountTextDAO:SetTextColor(1, 1, 1)
-- Player 1 "PP Side Bet" amount text
player1PPAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player1PPAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -315, 10)
player1PPAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player1PPAmountTextDAO:SetJustifyH("CENTER")
player1PPAmountTextDAO:SetText("PP Side Bet: N/A")
player1PPAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 1 "Total Bet" amount text
player1TotalAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player1TotalAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -315, -1)
player1TotalAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player1TotalAmountTextDAO:SetJustifyH("CENTER")
player1TotalAmountTextDAO:SetText("Total: N/A")
player1TotalAmountTextDAO:SetTextColor(1, 1, 0.5)
-- Card Total for Player 1
dealerFrameDAO.player1CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player1CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", -270, -15)
dealerFrameDAO.player1CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player1CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player1CardTotalTextDAO:SetText("")
-- Card Total (Split Hand 1) for Player 1
dealerFrameDAO.player1SplitHand1CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", -290, -35)
dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("")
-- Card Total (Split Hand 2) for Player 1
dealerFrameDAO.player1SplitHand2CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", -250, 5)
dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("")

-- ImagesDAO for Player 1
-- Main Bet
dealerFrameDAO.player1NormalCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1NormalCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1NormalCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -252, -38)
dealerFrameDAO.player1NormalCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player1NormalCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1NormalCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1NormalCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1NormalCoinsDAO:Hide()
-- Split Bet Hand 2
dealerFrameDAO.player1SplitHand2CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1SplitHand2CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1SplitHand2CoinsDAO:SetPoint("CENTER", dealerFrameDAO, -235, -32)
dealerFrameDAO.player1SplitHand2CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player1SplitHand2CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1SplitHand2CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1SplitHand2CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1SplitHand2CoinsDAO:Hide()
-- Split Double Bet Hand 2
dealerFrameDAO.player1SplitHand2DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1SplitHand2DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1SplitHand2DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -235, -32)
dealerFrameDAO.player1SplitHand2DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player1SplitHand2DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1SplitHand2DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1SplitHand2DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1SplitHand2DoubleCoinsDAO:Hide()
-- Split Bet Hand 1
dealerFrameDAO.player1SplitHand1CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1SplitHand1CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1SplitHand1CoinsDAO:SetPoint("CENTER", dealerFrameDAO, -257, -53)
dealerFrameDAO.player1SplitHand1CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player1SplitHand1CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1SplitHand1CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1SplitHand1CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1SplitHand1CoinsDAO:Hide()
-- Split Double Bet Hand 1
dealerFrameDAO.player1SplitHand1DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1SplitHand1DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1SplitHand1DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -257, -53)
dealerFrameDAO.player1SplitHand1DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player1SplitHand1DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1SplitHand1DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1SplitHand1DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1SplitHand1DoubleCoinsDAO:Hide()
-- Double Bet
dealerFrameDAO.player1DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -252, -38)
dealerFrameDAO.player1DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player1DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1DoubleCoinsDAO:Hide()
-- PP Bet
dealerFrameDAO.player1PPCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1PPCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1PPCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -194, -29)
dealerFrameDAO.player1PPCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsHalfBet.tga")
dealerFrameDAO.player1PPCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1PPCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1PPCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1PPCoinsDAO:Hide()
-- 21+3 Bet
dealerFrameDAO.player1213CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1213CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1213CoinsDAO:SetPoint("CENTER", dealerFrameDAO, -246, -100)
dealerFrameDAO.player1213CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsHalfBet.tga")
dealerFrameDAO.player1213CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1213CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1213CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1213CoinsDAO:Hide()
-- Win
dealerFrameDAO.player1NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -252, -38)
dealerFrameDAO.player1NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player1NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1NormalWinCoinsDAO:Hide()
-- Split Win Hand 2
dealerFrameDAO.player1SplitHand2NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1SplitHand2NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1SplitHand2NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -235, -32)
dealerFrameDAO.player1SplitHand2NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player1SplitHand2NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1SplitHand2NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1SplitHand2NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1SplitHand2NormalWinCoinsDAO:Hide()
-- Split Win Hand 1
dealerFrameDAO.player1SplitHand1NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1SplitHand1NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1SplitHand1NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -257, -53)
dealerFrameDAO.player1SplitHand1NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player1SplitHand1NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1SplitHand1NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1SplitHand1NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1SplitHand1NormalWinCoinsDAO:Hide()
-- Blackjack Win
dealerFrameDAO.player1BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -252, -38)
dealerFrameDAO.player1BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player1BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1BJWinCoinsDAO:Hide()
-- Split BJ Win Hand 2
dealerFrameDAO.player1SplitHand2BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1SplitHand2BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1SplitHand2BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -235, -32)
dealerFrameDAO.player1SplitHand2BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player1SplitHand2BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1SplitHand2BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1SplitHand2BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1SplitHand2BJWinCoinsDAO:Hide()
-- Split BJ Win Hand 1
dealerFrameDAO.player1SplitHand1BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1SplitHand1BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1SplitHand1BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -257, -53)
dealerFrameDAO.player1SplitHand1BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player1SplitHand1BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1SplitHand1BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1SplitHand1BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1SplitHand1BJWinCoinsDAO:Hide()
-- PP Win
dealerFrameDAO.player1PPWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1PPWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1PPWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -202, -23)
dealerFrameDAO.player1PPWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player1PPWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1PPWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1PPWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1PPWinCoinsDAO:Hide()
-- 21+3 Win
dealerFrameDAO.player1213WinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player1213WinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player1213WinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -255, -95)
dealerFrameDAO.player1213WinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player1213WinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player1213WinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player1213WinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player1213WinCoinsDAO:Hide()

-- Labels for Player 1
-- Main Bet AmountDAO
dealerFrameDAO.player1MainBetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player1MainBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -235, -12)
dealerFrameDAO.player1MainBetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player1MainBetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Split Hand 1 Bet AmountDAO
dealerFrameDAO.player1SplitHand1LabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player1SplitHand1LabelDAO:SetPoint("CENTER", dealerFrameDAO, -240, -27)
dealerFrameDAO.player1SplitHand1LabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player1SplitHand1LabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Split Hand 2 Bet AmountDAO
dealerFrameDAO.player1SplitHand2LabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player1SplitHand2LabelDAO:SetPoint("CENTER", dealerFrameDAO, -218, -6)
dealerFrameDAO.player1SplitHand2LabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player1SplitHand2LabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Perfect Pairs AmountDAO
dealerFrameDAO.player1PPBetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player1PPBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -185, -11)
dealerFrameDAO.player1PPBetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player1PPBetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- 21+3 AmountDAO
dealerFrameDAO.player1213BetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player1213BetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -237, -81)
dealerFrameDAO.player1213BetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player1213BetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Insurance YES for Player 1
player1InsuranceYesIconDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
player1InsuranceYesIconDAO:SetSize(14, 14)
player1InsuranceYesIconDAO:SetPoint("CENTER", dealerFrameDAO, -350, 80)
player1InsuranceYesIconDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\insuranceYes.tga")
player1InsuranceYesIconDAO:SetDrawLayer("OVERLAY")
player1InsuranceYesIconDAO:Hide()
-- Insurance NO for Player 1
player1InsuranceNoIconDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
player1InsuranceNoIconDAO:SetSize(14, 14)
player1InsuranceNoIconDAO:SetPoint("CENTER", dealerFrameDAO, -350, 80)
player1InsuranceNoIconDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\insuranceNo.tga")
player1InsuranceNoIconDAO:SetDrawLayer("OVERLAY")
player1InsuranceNoIconDAO:Hide()

function player1HandleInsuranceYesDAO(messageDAO)
    player1InsuranceYesIconDAO:Show()
    player1InsuranceBetValueDAO = string.match(messageDAO, "(%d+)G")
    if player1InsuranceBetValueDAO then
        player1InsuranceAmountTextDAO:SetText("Insurance: " .. player1InsuranceBetValueDAO .. " G")
        player1TotalBetAmountDAO = player1TotalBetAmountDAO + player1InsuranceBetValueDAO
        player1TotalAmountTextDAO:SetText("Total: " .. player1TotalBetAmountDAO .. " G")
    end

    player1BankingTotalWageredDAO = player1BankingTotalWageredDAO + tonumber(player1InsuranceBetValueDAO)
    bankingFrameDAO.player1totalWageredAmountDAO:SetText(player1BankingTotalWageredDAO .. " G")

    player1BankingBankrollDAO = player1BankingBankrollDAO - tonumber(player1InsuranceBetValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

end

function player1InsuranceWinDAO(messageDAO)
    player1InsuranceBetAmountValueDAO = tonumber(string.match(player1InsuranceAmountTextDAO:GetText(), "%d+"))
    if player1InsuranceBetAmountValueDAO then
        player1InsuranceWinAmountValueDAO = player1InsuranceBetAmountValueDAO * 3

        player1InsuranceProfitValueDAO = player1InsuranceWinAmountValueDAO - player1InsuranceBetAmountValueDAO

        player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1InsuranceProfitValueDAO)
        bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

        player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1InsuranceProfitValueDAO)
        bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

        if player1BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end
        
        player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1InsuranceWinAmountValueDAO)
        bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

        player1InsuranceAmountTextDAO:SetText("Insurance: " .. player1InsuranceWinAmountValueDAO .. " G")
        player1InsuranceAmountTextDAO:SetTextColor(0, 1, 0)

    end

end

function player1InsuranceLossDAO(messageDAO)
    if player1InsuranceAmountTextDAO:GetText() == "Insurance: N/A" then
        print("")
    else
        player1InsuranceBetAmountValueDAO = tonumber(string.match(player1InsuranceAmountTextDAO:GetText(), "%d+"))
        if player1InsuranceBetAmountValueDAO then

            player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1InsuranceBetAmountValueDAO)
            bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

            player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1InsuranceBetAmountValueDAO)
            bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")
        end
    end
end

function player1HandleInsuranceNoDAO(messageDAO)
    player1InsuranceNoIconDAO:Show()
    player1InsuranceAmountTextDAO:SetText("Insurance: 0 G")
end

-- Player 1 Main Bet Image
function player1PlaceMainBetDAO(messageDAO)
    dealerFrameDAO.player1NormalCoinsDAO:Show()
end

-- Player 1 Main Bet Text
function player1PlaceMainBetTextDAO(AmountDAO)
    dealerFrameDAO.player1MainBetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player1MainBetLabelDAO:Show()
end

-- Player 1 Double Bet Image
function player1PlaceDoubleBetDAO(messageDAO)
    dealerFrameDAO.player1NormalCoinsDAO:Hide()
    dealerFrameDAO.player1DoubleCoinsDAO:Show()
end

-- Player 1 Push
function player1PushDAO(messageDAO)
    player1MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1MainBetLabelDAO:GetText(), "%d+"))
    if player1MainBetAmountValueDAO then

        dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1MainBetAmountValueDAO)
        bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

        local player1PPBetTextDAO = dealerFrameDAO.player1PPBetLabelDAO:GetText()

        if player1PPBetTextDAO and player1PPBetTextDAO ~= "" then
            player1PPBetAmountValueDAO = tonumber(string.match(player1PPBetTextDAO, "%d+"))
            
            if player1PPBetAmountValueDAO then
                if player1PPSideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player1213BetTextDAO = dealerFrameDAO.player1213BetLabelDAO:GetText()

        if player1213BetTextDAO and player1213BetTextDAO ~= "" then
            player1213BetAmountValueDAO = tonumber(string.match(player1213BetTextDAO, "%d+"))

            if player1213BetAmountValueDAO then
                if player1213SideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 1 Split Hand 1 Push
function player1SplitH1PushDAO()
    
    player1SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1LabelDAO:GetText(), "%d+"))
    if player1SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

    end
end

-- Player 1 Split Hand 2 Push
function player1SplitH2PushDAO()
    
    player1SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2LabelDAO:GetText(), "%d+"))
    if player1SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

        local player1PPBetTextDAO = dealerFrameDAO.player1PPBetLabelDAO:GetText()

        if player1PPBetTextDAO and player1PPBetTextDAO ~= "" then
            player1PPBetAmountValueDAO = tonumber(string.match(player1PPBetTextDAO, "%d+"))
            
            if player1PPBetAmountValueDAO then
                if player1PPSideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player1213BetTextDAO = dealerFrameDAO.player1213BetLabelDAO:GetText()

        if player1213BetTextDAO and player1213BetTextDAO ~= "" then
            player1213BetAmountValueDAO = tonumber(string.match(player1213BetTextDAO, "%d+"))

            if player1213BetAmountValueDAO then
                if player1213SideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 1 Loss
function player1LossDAO(messageDAO)
    player1MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1MainBetLabelDAO:GetText(), "%d+"))
    if player1MainBetAmountValueDAO then

        dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)

        player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1MainBetAmountValueDAO)
        bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

        player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1MainBetAmountValueDAO)
        bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

        if player1BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player1PPBetTextDAO = dealerFrameDAO.player1PPBetLabelDAO:GetText()

        if player1PPBetTextDAO and player1PPBetTextDAO ~= "" then
            player1PPBetAmountValueDAO = tonumber(string.match(player1PPBetTextDAO, "%d+"))
            
            if player1PPBetAmountValueDAO then
                if player1PPSideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player1213BetTextDAO = dealerFrameDAO.player1213BetLabelDAO:GetText()

        if player1213BetTextDAO and player1213BetTextDAO ~= "" then
            player1213BetAmountValueDAO = tonumber(string.match(player1213BetTextDAO, "%d+"))

            if player1213BetAmountValueDAO then
                if player1213SideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 1 Split Hand 1 Loss
function player1SplitH1LossDAO()
    player1SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1LabelDAO:GetText(), "%d+"))
    if player1SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)

        player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

        player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

        if player1BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

    end

end

-- Player 1 Split Hand 2 Loss
function player1SplitH2LossDAO()
    player1SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2LabelDAO:GetText(), "%d+"))
    if player1SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)

        player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

        player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

        if player1BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player1PPBetTextDAO = dealerFrameDAO.player1PPBetLabelDAO:GetText()

        if player1PPBetTextDAO and player1PPBetTextDAO ~= "" then
            player1PPBetAmountValueDAO = tonumber(string.match(player1PPBetTextDAO, "%d+"))
            
            if player1PPBetAmountValueDAO then
                if player1PPSideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player1213BetTextDAO = dealerFrameDAO.player1213BetLabelDAO:GetText()

        if player1213BetTextDAO and player1213BetTextDAO ~= "" then
            player1213BetAmountValueDAO = tonumber(string.match(player1213BetTextDAO, "%d+"))

            if player1213BetAmountValueDAO then
                if player1213SideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 1 Win
function player1WinDAO(messageDAO)
    
    player1MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1MainBetLabelDAO:GetText(), "%d+"))
    if player1MainBetAmountValueDAO then

        dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(0, 1, 0)

        player1NormalWinAmountValueDAO = player1MainBetAmountValueDAO * 2
        dealerFrameDAO.player1MainBetLabelDAO:SetText(player1NormalWinAmountValueDAO .. " G")
        player1MainBetAmountTextDAO:SetText("Main Bet: " .. player1NormalWinAmountValueDAO .. " G")

        player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1MainBetAmountValueDAO)
        bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

        player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1MainBetAmountValueDAO)
        bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

        player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1NormalWinAmountValueDAO)
        bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

        if player1BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player1PPBetTextDAO = dealerFrameDAO.player1PPBetLabelDAO:GetText()

        if player1PPBetTextDAO and player1PPBetTextDAO ~= "" then
            player1PPBetAmountValueDAO = tonumber(string.match(player1PPBetTextDAO, "%d+"))

            if player1PPBetAmountValueDAO then
                if player1PPSideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player1213BetTextDAO = dealerFrameDAO.player1213BetLabelDAO:GetText()

        if player1213BetTextDAO and player1213BetTextDAO ~= "" then
            player1213BetAmountValueDAO = tonumber(string.match(player1213BetTextDAO, "%d+"))
            
            if player1213BetAmountValueDAO then
                if player1213SideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

    end
    
    dealerFrameDAO.player1NormalCoinsDAO:Hide()
    dealerFrameDAO.player1NormalWinCoinsDAO:Show()
end

-- Player 1 Split Hand 1 Win
function player1SplitH1WinDAO(messageDAO)
    player1SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1LabelDAO:GetText(), "%d+"))
    if player1SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(0, 1, 0)

        player1SplitHand1NormalWinAmountValueDAO = player1SplitHand1BetAmountValueDAO * 2
        dealerFrameDAO.player1SplitHand1LabelDAO:SetText(player1SplitHand1NormalWinAmountValueDAO .. " G")
        player1Hand1BetAmountTextDAO:SetText("H1: " .. player1SplitHand1NormalWinAmountValueDAO .. " G")

        player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")
    
        player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")
    
        player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1SplitHand1NormalWinAmountValueDAO)
        bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

        if player1BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

    end

    dealerFrameDAO.player1SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player1SplitHand1NormalWinCoinsDAO:Show()

end

-- Player 1 Split Hand 2 Win
function player1SplitH2WinDAO(messageDAO)
    player1SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2LabelDAO:GetText(), "%d+"))
    if player1SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(0, 1, 0)

        player1SplitHand2NormalWinAmountValueDAO = player1SplitHand2BetAmountValueDAO * 2
        dealerFrameDAO.player1SplitHand2LabelDAO:SetText(player1SplitHand2NormalWinAmountValueDAO .. " G")
        player1Hand2BetAmountTextDAO:SetText("H2: " .. player1SplitHand2NormalWinAmountValueDAO .. " G")

        player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")
    
        player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")
    
        player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1SplitHand2NormalWinAmountValueDAO)
        bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

        if player1BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player1PPBetTextDAO = dealerFrameDAO.player1PPBetLabelDAO:GetText()

        if player1PPBetTextDAO and player1PPBetTextDAO ~= "" then
            player1PPBetAmountValueDAO = tonumber(string.match(player1PPBetTextDAO, "%d+"))

            if player1PPBetAmountValueDAO then
                if player1PPSideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1PPBetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player1213BetTextDAO = dealerFrameDAO.player1213BetLabelDAO:GetText()

        if player1213BetTextDAO and player1213BetTextDAO ~= "" then
            player1213BetAmountValueDAO = tonumber(string.match(player1213BetTextDAO, "%d+"))
            
            if player1213BetAmountValueDAO then
                if player1213SideBetWinDAO == false then

                    player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1213BetAmountValueDAO)
                    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                    if player1BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

    end

    dealerFrameDAO.player1SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player1SplitHand2NormalWinCoinsDAO:Show()

end

-- Player 1 BJ Win
function player1BJWinDAO(messageDAO)
    player1MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1MainBetLabelDAO:GetText(), "%d+"))
    if player1MainBetAmountValueDAO then
        player1BJWinAmountValueDAO = player1MainBetAmountValueDAO * 2.5
        dealerFrameDAO.player1MainBetLabelDAO:SetText(player1BJWinAmountValueDAO .. " G")
        player1MainBetAmountTextDAO:SetText("Main Bet: " .. player1BJWinAmountValueDAO .. " G")
    end

    player1BJProfitvalueDAO = player1BJWinAmountValueDAO - player1MainBetAmountValueDAO

    player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1BJProfitvalueDAO)
    bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1BJProfitvalueDAO)
    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

    player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1BJWinAmountValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

    if player1BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player1PPBetTextDAO = dealerFrameDAO.player1PPBetLabelDAO:GetText()

    if player1PPBetTextDAO and player1PPBetTextDAO ~= "" then
        player1PPBetAmountValueDAO = tonumber(string.match(player1PPBetTextDAO, "%d+"))

        if player1PPBetAmountValueDAO then
            if player1PPSideBetWinDAO == false then

                player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1PPBetAmountValueDAO)
                bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1PPBetAmountValueDAO)
                bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                if player1BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    local player1213BetTextDAO = dealerFrameDAO.player1213BetLabelDAO:GetText()

    if player1213BetTextDAO and player1213BetTextDAO ~= "" then
        player1213BetAmountValueDAO = tonumber(string.match(player1213BetTextDAO, "%d+"))
        
        if player1213BetAmountValueDAO then
            if player1213SideBetWinDAO == false then

                player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1213BetAmountValueDAO)
                bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1213BetAmountValueDAO)
                bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                if player1BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

    dealerFrameDAO.player1NormalCoinsDAO:Hide()
    dealerFrameDAO.player1BJWinCoinsDAO:Show()

end

-- Player 1 Split Hand 1 BJ Win
function player1SplitH1BJDAO(messageDAO)
    player1SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1LabelDAO:GetText(), "%d+"))
    if player1SplitHand1BetAmountValueDAO then
        player1SplitHand1BJWinAmountValueDAO = player1SplitHand1BetAmountValueDAO * 2.5
        dealerFrameDAO.player1SplitHand1LabelDAO:SetText(player1SplitHand1BJWinAmountValueDAO .. " G")
        player1Hand1BetAmountTextDAO:SetText("H1: " .. player1SplitHand1BJWinAmountValueDAO .. " G")
    end

    player1SplitHand1BJProfitValueDAO = player1SplitHand1BJWinAmountValueDAO - player1SplitHand1BetAmountValueDAO

    player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1SplitHand1BJProfitValueDAO)
    bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1SplitHand1BJProfitValueDAO)
    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

    player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1SplitHand1BJWinAmountValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

    if player1BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player1PPBetTextDAO = dealerFrameDAO.player1PPBetLabelDAO:GetText()

    dealerFrameDAO.player1SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player1SplitHand1BJWinCoinsDAO:Show()

end

-- Player 1 Split Hand 2 BJ Win
function player1SplitH2BJDAO(messageDAO)
    player1SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2LabelDAO:GetText(), "%d+"))
    if player1SplitHand2BetAmountValueDAO then
        player1SplitHand2BJWinAmountValueDAO = player1SplitHand2BetAmountValueDAO * 2.5
        dealerFrameDAO.player1SplitHand2LabelDAO:SetText(player1SplitHand2BJWinAmountValueDAO .. " G")
        player1Hand2BetAmountTextDAO:SetText("H2: " .. player1SplitHand2BJWinAmountValueDAO .. " G")
    end

    player1SplitHand2BJProfitValueDAO = player1SplitHand2BJWinAmountValueDAO - player1SplitHand2BetAmountValueDAO

    player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1SplitHand2BJProfitValueDAO)
    bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1SplitHand2BJProfitValueDAO)
    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

    player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1SplitHand2BJWinAmountValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

    if player1BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player1PPBetTextDAO = dealerFrameDAO.player1PPBetLabelDAO:GetText()

    if player1PPBetTextDAO and player1PPBetTextDAO ~= "" then
        player1PPBetAmountValueDAO = tonumber(string.match(player1PPBetTextDAO, "%d+"))

        if player1PPBetAmountValueDAO then
            if player1PPSideBetWinDAO == false then

                player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1PPBetAmountValueDAO)
                bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1PPBetAmountValueDAO)
                bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                if player1BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    local player1213BetTextDAO = dealerFrameDAO.player1213BetLabelDAO:GetText()

    if player1213BetTextDAO and player1213BetTextDAO ~= "" then
        player1213BetAmountValueDAO = tonumber(string.match(player1213BetTextDAO, "%d+"))
        
        if player1213BetAmountValueDAO then
            if player1213SideBetWinDAO == false then

                player1BankingTotalLostDAO = player1BankingTotalLostDAO + tonumber(player1213BetAmountValueDAO)
                bankingFrameDAO.player1totalLostAmountDAO:SetText(player1BankingTotalLostDAO .. " G")

                player1BankingTotalProfitDAO = player1BankingTotalProfitDAO - tonumber(player1213BetAmountValueDAO)
                bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

                if player1BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    dealerFrameDAO.player1SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player1SplitHand2BJWinCoinsDAO:Show()

end

-- Player 1 Main Bet Complete Function
function player1HandleMainBetDAO(messageDAO)
    player1PlaceMainBetDAO()
    player1ActiveDAO = true
    local player1MainBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player1MainBetAmountValueDAO then
            player1PlaceMainBetTextDAO(player1MainBetAmountValueDAO)
            player1MainBetAmountTextDAO:SetText("Main Bet: " .. player1MainBetAmountValueDAO .. " G")
            player1TotalBetAmountDAO = player1TotalBetAmountDAO + tonumber(player1MainBetAmountValueDAO)
            player1TotalAmountTextDAO:SetText("Total: " .. player1TotalBetAmountDAO .. " G")
        else
    end

    player1BankingTotalWageredDAO = player1BankingTotalWageredDAO + tonumber(player1MainBetAmountValueDAO)
    bankingFrameDAO.player1totalWageredAmountDAO:SetText(player1BankingTotalWageredDAO .. " G")

    player1BankingBankrollDAO = player1BankingBankrollDAO - tonumber(player1MainBetAmountValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

end

-- Player 1 Double Bet Complete Function
function player1HandleDoubleBetDAO(messageDAO)
    player1PlaceDoubleBetDAO()
    local player1DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player1OriginalBetAmountValueDAO = tonumber(player1DoubleBetAmountValueDAO) / 2
    if player1DoubleBetAmountValueDAO then
        player1PlaceMainBetTextDAO(player1DoubleBetAmountValueDAO)
        player1MainBetAmountTextDAO:SetText("Main Bet: " .. player1DoubleBetAmountValueDAO .. " G")
        player1TotalBetAmountDAO = player1TotalBetAmountDAO + player1OriginalBetAmountValueDAO
        player1TotalAmountTextDAO:SetText("Total: " .. player1TotalBetAmountDAO .. " G")
    else
    end

    player1BankingTotalWageredDAO = player1BankingTotalWageredDAO + tonumber(player1OriginalBetAmountValueDAO)
    bankingFrameDAO.player1totalWageredAmountDAO:SetText(player1BankingTotalWageredDAO .. " G")

    player1BankingBankrollDAO = player1BankingBankrollDAO - tonumber(player1OriginalBetAmountValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

end

-- Player 1 Split Hand 1 Double Bet Complete Function
function player1SplitHand1DoubleBetDAO(messageDAO)
    
    dealerFrameDAO.player1SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player1SplitHand1DoubleCoinsDAO:Show()

    local player1SplitH1DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player1SplitH1OriginalBetAmountValueDAO = tonumber(player1SplitH1DoubleBetAmountValueDAO) / 2
    if player1SplitH1DoubleBetAmountValueDAO then
        dealerFrameDAO.player1SplitHand1LabelDAO:SetText(player1SplitH1DoubleBetAmountValueDAO .. " G")
        player1Hand1BetAmountTextDAO:SetText("H1: " .. player1SplitH1DoubleBetAmountValueDAO .. " G")
        player1TotalBetAmountDAO = player1TotalBetAmountDAO + player1SplitH1OriginalBetAmountValueDAO
        player1TotalAmountTextDAO:SetText("Total: " .. player1TotalBetAmountDAO .. " G")
    end

    player1BankingTotalWageredDAO = player1BankingTotalWageredDAO + tonumber(player1SplitH1OriginalBetAmountValueDAO)
    bankingFrameDAO.player1totalWageredAmountDAO:SetText(player1BankingTotalWageredDAO .. " G")

    player1BankingBankrollDAO = player1BankingBankrollDAO - tonumber(player1SplitH1OriginalBetAmountValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

end

-- Player 1 Split Hand 2 Double Bet Complete Function
function player1SplitHand2DoubleBetDAO(messageDAO)
    
    dealerFrameDAO.player1SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player1SplitHand2DoubleCoinsDAO:Show()

    local player1SplitH2DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player1SplitH2OriginalBetAmountValueDAO = tonumber(player1SplitH2DoubleBetAmountValueDAO) / 2
    if player1SplitH2DoubleBetAmountValueDAO then
        dealerFrameDAO.player1SplitHand2LabelDAO:SetText(player1SplitH2DoubleBetAmountValueDAO .. " G")
        player1Hand2BetAmountTextDAO:SetText("H2: " .. player1SplitH2DoubleBetAmountValueDAO .. " G")
        player1TotalBetAmountDAO = player1TotalBetAmountDAO + player1SplitH2OriginalBetAmountValueDAO
        player1TotalAmountTextDAO:SetText("Total: " .. player1TotalBetAmountDAO .. " G")
    end

    player1BankingTotalWageredDAO = player1BankingTotalWageredDAO + tonumber(player1SplitH2OriginalBetAmountValueDAO)
    bankingFrameDAO.player1totalWageredAmountDAO:SetText(player1BankingTotalWageredDAO .. " G")

    player1BankingBankrollDAO = player1BankingBankrollDAO - tonumber(player1SplitH2OriginalBetAmountValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

end

-- Player 1 Split Hand Bet Text
function player1SplitHand1BetTextDAO(AmountDAO)
    dealerFrameDAO.player1MainBetLabelDAO:Hide()
    dealerFrameDAO.player1MainBetLabelDAO:SetText("")
    dealerFrameDAO.player1SplitHand1LabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player1SplitHand1LabelDAO:Show()
    dealerFrameDAO.player1SplitHand2LabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player1SplitHand2LabelDAO:Show()
end

-- Player 1 Split Bet Image
function player1PlaceSplitBetDAO(messageDAO)
    dealerFrameDAO.player1NormalCoinsDAO:Hide()
    dealerFrameDAO.player1SplitHand2CoinsDAO:Show()
    dealerFrameDAO.player1SplitHand1CoinsDAO:Show()
end

-- Player 1 Place Initial Card ImagesDAO
function player1PlaceSplitCardsDAO(messageDAO)

    -- Players: 1
    if player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[3]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[3]
        turnDAO = 8 -- Player 1: 2nd Card (Split H1)

    -- Players: 1, 2
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[4]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[4]
        turnDAO = 10 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 3
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[4]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[4]
        turnDAO = 10 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 4
    elseif player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[4]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[4]
        turnDAO = 10 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 5
    elseif player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[4]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[4]
        turnDAO = 10 -- Player 1: 2nd Card (Split H1)

    -- Players: 1, 2, 3
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[5]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[5]
        turnDAO = 12 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 2, 4
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[5]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[5]
        turnDAO = 12 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 2, 5
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[5]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[5]
        turnDAO = 12 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 3, 4
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[5]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[5]
        turnDAO = 12 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 3, 5
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[5]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[5]
        turnDAO = 12 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 4, 5
    elseif player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[5]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[5]
        turnDAO = 12 -- Player 1: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[6]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[6]
        turnDAO = 14 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 2, 3, 5
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[6]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[6]
        turnDAO = 14 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 2, 4, 5
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[6]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[6]
        turnDAO = 14 -- Player 1: 2nd Card (Split H1)
    -- Players: 1, 3, 4, 5
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[6]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[6]
        turnDAO = 14 -- Player 1: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4, 5
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[7]:Hide()
        player1cardName1DAO = dealtCardsDAO[1]
        player1cardName2DAO = dealtCardsDAO[6]
        turnDAO = 16 -- Player 1: 2nd Card (Split H1)
    end

    player1cardImageFile1DAO = nil
    player1cardImageFile2DAO = nil

    for filenameDAO, cardDescriptionDAO in pairs(cardNamesDAO) do
        if cardDescriptionDAO == player1cardName1DAO then
            player1cardImageFile1DAO = filenameDAO
            break
        end
    end

    for filenameDAO, cardDescriptionDAO in pairs(cardNamesDAO) do
        if cardDescriptionDAO == player1cardName2DAO then
            player1cardImageFile2DAO = filenameDAO
            break
        end
    end

    player1NewCardImage1DAO = CreateFrame("Frame", nil, dealerFrameDAO)
    player1NewCardImage1DAO:SetSize(24, 48)
    player1NewCardImage1DAO:SetPoint("CENTER", dealerFrameDAO, -210, -105)
    player1NewCardImage1DAO.texture = player1NewCardImage1DAO:CreateTexture()
    player1NewCardImage1DAO.texture:SetAllPoints()
    player1NewCardImage1DAO.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. player1cardImageFile1DAO)
    player1NewCardImage1DAO:Show()

    player1NewCardImage2DAO = CreateFrame("Frame", nil, dealerFrameDAO)
    player1NewCardImage2DAO:SetSize(24, 48)
    player1NewCardImage2DAO:SetPoint("CENTER", dealerFrameDAO, -180, -70)
    player1NewCardImage2DAO.texture = player1NewCardImage2DAO:CreateTexture()
    player1NewCardImage2DAO.texture:SetAllPoints()
    player1NewCardImage2DAO.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. player1cardImageFile2DAO)
    player1NewCardImage2DAO:Show()

end

-- Player 1 Split Function
function player1HandleSplitDAO(messageDAO)
    player1PlaceSplitBetDAO()
    local player1MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player1MainBetLabelDAO:GetText(), "%d+"))
    if player1MainBetAmountValueDAO then
        player1SplitHand1BetTextDAO(player1MainBetAmountValueDAO)
        player1MainBetAmountTextDAO:Hide()
        player1Hand1BetAmountTextDAO:Show()
        player1Hand2BetAmountTextDAO:Show()
        player1Hand1BetAmountTextDAO:SetText("H1: " .. player1MainBetAmountValueDAO .. " G")
        player1Hand2BetAmountTextDAO:SetText("H2: " .. player1MainBetAmountValueDAO .. " G")
        player1TotalBetAmountDAO = player1TotalBetAmountDAO + player1MainBetAmountValueDAO
        player1TotalAmountTextDAO:SetText("Total: " .. player1TotalBetAmountDAO .. " G")
    else
    end 

    dealerFrameDAO.player1CardTotalTextDAO:SetText("")
    dealerFrameDAO.player1CardTotalTextDAO:Hide()

    if player1RunningTotalDAO == 2 then
        dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("1 or 11")
        dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("1 or 11")
        dealerFrameDAO.player1SplitHand1CardTotalTextDAO:Show()
        dealerFrameDAO.player1SplitHand2CardTotalTextDAO:Show()
    else
        dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText(player1S1RunningTotalDAO)
        dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText(player1S2RunningTotalDAO)
        dealerFrameDAO.player1SplitHand1CardTotalTextDAO:Show()
        dealerFrameDAO.player1SplitHand2CardTotalTextDAO:Show()
    end

    player1BankingTotalWageredDAO = player1BankingTotalWageredDAO + tonumber(player1MainBetAmountValueDAO)
    bankingFrameDAO.player1totalWageredAmountDAO:SetText(player1BankingTotalWageredDAO .. " G")

    player1BankingBankrollDAO = player1BankingBankrollDAO - tonumber(player1MainBetAmountValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")
    
    player1PlaceSplitCardsDAO()
    
end

-- Player 1 PP Bet Image
function player1PlacePPBetDAO(messageDAO)
    dealerFrameDAO.player1PPCoinsDAO:Show()
end

-- Player 1 PP Bet Text
function player1PlacePPBetTextDAO(AmountDAO)
    dealerFrameDAO.player1PPBetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player1PPBetLabelDAO:Show()
end

-- Player 1 PP Win
function player1PPWinDAO(messageDAO)
    dealerFrameDAO.player1PPCoinsDAO:Hide()
    dealerFrameDAO.player1PPWinCoinsDAO:Show()
    dealerFrameDAO.player1PPBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -185, 4)
end

-- Player 1 PP Bet Complete Function
function player1HandlePPBetDAO(messageDAO)
    player1PlacePPBetDAO()
    local player1PPBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player1PPBetAmountValueDAO then
            player1PlacePPBetTextDAO(player1PPBetAmountValueDAO)
            player1PPAmountTextDAO:SetText("PP Side Bet: " .. player1PPBetAmountValueDAO .. " G")
            player1TotalBetAmountDAO = player1TotalBetAmountDAO + tonumber(player1PPBetAmountValueDAO)
            player1TotalAmountTextDAO:SetText("Total: " .. player1TotalBetAmountDAO .. " G")
        else
    end

    player1BankingTotalWageredDAO = player1BankingTotalWageredDAO + tonumber(player1PPBetAmountValueDAO)
    bankingFrameDAO.player1totalWageredAmountDAO:SetText(player1BankingTotalWageredDAO .. " G")

    player1BankingBankrollDAO = player1BankingBankrollDAO - tonumber(player1PPBetAmountValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

end

-- Player 1 21+3 Bet Image
function player1Place213BetDAO(messageDAO)
    dealerFrameDAO.player1213CoinsDAO:Show()
end

-- Player 1 21+3 Bet Text
function player1Place213BetTextDAO(AmountDAO)
    dealerFrameDAO.player1213BetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player1213BetLabelDAO:Show()
end

-- Player 1 21+3 Win
function player1213WinDAO(messageDAO)
    dealerFrameDAO.player1213CoinsDAO:Hide()
    dealerFrameDAO.player1213WinCoinsDAO:Show()
    dealerFrameDAO.player1213BetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -237, -68)
end

-- Player 1 21+3 Bet Complete Function
function player1Handle213BetDAO(messageDAO)
    player1Place213BetDAO()
    local player1213BetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player1213BetAmountValueDAO then
            player1Place213BetTextDAO(player1213BetAmountValueDAO)
            player1213AmountTextDAO:SetText("21+3 Side Bet: " .. player1213BetAmountValueDAO .. " G")
            player1TotalBetAmountDAO = player1TotalBetAmountDAO + tonumber(player1213BetAmountValueDAO)
            player1TotalAmountTextDAO:SetText("Total: " .. player1TotalBetAmountDAO .. " G")
        else
    end

    player1BankingTotalWageredDAO = player1BankingTotalWageredDAO + tonumber(player1213BetAmountValueDAO)
    bankingFrameDAO.player1totalWageredAmountDAO:SetText(player1BankingTotalWageredDAO .. " G")

    player1BankingBankrollDAO = player1BankingBankrollDAO - tonumber(player1213BetAmountValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

end

function player1MixedPairWinDAO(messageDAO)
    player1PPSideBetWinDAO = true
    player1PPAmountTextValueDAO = tonumber(string.match(player1PPAmountTextDAO:GetText(), "%d+"))
    if player1PPAmountTextValueDAO then
        player1PPWinValueDAO = player1PPAmountTextValueDAO * mixedPairPayoutReturnDAO
        player1PPAmountTextDAO:SetText("PP Side Bet: " .. player1PPWinValueDAO .. " G")
        player1PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player1PPBetLabelDAO:SetText(player1PPWinValueDAO .. " G")
    end

    player1PPProfitValueDAO = player1PPWinValueDAO - player1PPAmountTextValueDAO

    player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1PPProfitValueDAO)
    bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1PPProfitValueDAO)
    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

    if player1BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1PPWinValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

    player1PPWinDAO()
end

function player1ColouredPairWinDAO(messageDAO)
    player1PPSideBetWinDAO = true
    player1PPAmountTextValueDAO = tonumber(string.match(player1PPAmountTextDAO:GetText(), "%d+"))
    if player1PPAmountTextValueDAO then
        player1PPWinValueDAO = player1PPAmountTextValueDAO * colouredPairPayoutReturnDAO
        player1PPAmountTextDAO:SetText("PP Side Bet: " .. player1PPWinValueDAO .. " G")
        player1PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player1PPBetLabelDAO:SetText(player1PPWinValueDAO .. " G")
    end

    player1PPProfitValueDAO = player1PPWinValueDAO - player1PPAmountTextValueDAO

    player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1PPProfitValueDAO)
    bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1PPProfitValueDAO)
    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

    if player1BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1PPWinValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

    player1PPWinDAO()
end

function player1PerfectPairWinDAO(messageDAO)
    player1PPSideBetWinDAO = true
    player1PPAmountTextValueDAO = tonumber(string.match(player1PPAmountTextDAO:GetText(), "%d+"))
    if player1PPAmountTextValueDAO then
        player1PPWinValueDAO = player1PPAmountTextValueDAO * perfectPairPayoutReturnDAO
        player1PPAmountTextDAO:SetText("PP Side Bet: " .. player1PPWinValueDAO .. " G")
        player1PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player1PPBetLabelDAO:SetText(player1PPWinValueDAO .. " G")
    end

    player1PPProfitValueDAO = player1PPWinValueDAO - player1PPAmountTextValueDAO

    player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1PPProfitValueDAO)
    bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1PPProfitValueDAO)
    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

    if player1BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1PPWinValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

    player1PPWinDAO()
end

function player1SuitedThreeOfAKindWinDAO(messageDAO)
    player1213SideBetWinDAO = true
    player1213AmountTextValueDAO = tonumber(string.match(player1213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player1213AmountTextValueDAO then
        player1213WinValueDAO = player1213AmountTextValueDAO * suitedThreeOfAKindPayoutReturnDAO
        player1213AmountTextDAO:SetText("21+3 Side Bet: " .. player1213WinValueDAO .. " G")
        player1213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player1213BetLabelDAO:SetText(player1213WinValueDAO .. " G")
    end

    player1213ProfitValueDAO = player1213WinValueDAO - player1213AmountTextValueDAO

    player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1213ProfitValueDAO)
    bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1213ProfitValueDAO)
    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

    if player1BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1213WinValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

    player1213WinDAO()
end

function player1StraightFlushWinDAO(messageDAO)
    player1213SideBetWinDAO = true
    player1213AmountTextValueDAO = tonumber(string.match(player1213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player1213AmountTextValueDAO then
        player1213WinValueDAO = player1213AmountTextValueDAO * straightFlushPayoutReturnDAO
        player1213AmountTextDAO:SetText("21+3 Side Bet: " .. player1213WinValueDAO .. " G")
        player1213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player1213BetLabelDAO:SetText(player1213WinValueDAO .. " G")
    end

    player1213ProfitValueDAO = player1213WinValueDAO - player1213AmountTextValueDAO

    player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1213ProfitValueDAO)
    bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1213ProfitValueDAO)
    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

    if player1BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1213WinValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

    player1213WinDAO()
end

function player1ThreeOfAKindWinDAO(messageDAO)
    player1213SideBetWinDAO = true
    player1213AmountTextValueDAO = tonumber(string.match(player1213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player1213AmountTextValueDAO then
        player1213WinValueDAO = player1213AmountTextValueDAO * threeOfAKindPayoutReturnDAO
        player1213AmountTextDAO:SetText("21+3 Side Bet: " .. player1213WinValueDAO .. " G")
        player1213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player1213BetLabelDAO:SetText(player1213WinValueDAO .. " G")
    end

    player1213ProfitValueDAO = player1213WinValueDAO - player1213AmountTextValueDAO

    player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1213ProfitValueDAO)
    bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1213ProfitValueDAO)
    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

    if player1BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1213WinValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

    player1213WinDAO()
end

function player1StraightWinDAO(messageDAO)
    player1213SideBetWinDAO = true
    player1213AmountTextValueDAO = tonumber(string.match(player1213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player1213AmountTextValueDAO then
        player1213WinValueDAO = player1213AmountTextValueDAO * straightPayoutReturnDAO
        player1213AmountTextDAO:SetText("21+3 Side Bet: " .. player1213WinValueDAO .. " G")
        player1213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player1213BetLabelDAO:SetText(player1213WinValueDAO .. " G")
    end

    player1213ProfitValueDAO = player1213WinValueDAO - player1213AmountTextValueDAO

    player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1213ProfitValueDAO)
    bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1213ProfitValueDAO)
    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

    if player1BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1213WinValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")

    player1213WinDAO()
end

function player1FlushWinDAO(messageDAO)
    player1213SideBetWinDAO = true
    player1213AmountTextValueDAO = tonumber(string.match(player1213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player1213AmountTextValueDAO then
        player1213WinValueDAO = player1213AmountTextValueDAO * flushPayoutReturnDAO
        player1213AmountTextDAO:SetText("21+3 Side Bet: " .. player1213WinValueDAO .. " G")
        player1213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player1213BetLabelDAO:SetText(player1213WinValueDAO .. " G")
    end

    player1213ProfitValueDAO = player1213WinValueDAO - player1213AmountTextValueDAO

    player1BankingTotalWonDAO = player1BankingTotalWonDAO + tonumber(player1213ProfitValueDAO)
    bankingFrameDAO.player1totalWonAmountDAO:SetText(player1BankingTotalWonDAO .. " G")

    player1BankingTotalProfitDAO = player1BankingTotalProfitDAO + tonumber(player1213ProfitValueDAO)
    bankingFrameDAO.player1totalProfitAmountDAO:SetText(player1BankingTotalProfitDAO .. " G")

    if player1BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player1totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player1BankingBankrollDAO = player1BankingBankrollDAO + tonumber(player1213WinValueDAO)
    bankingFrameDAO.player1BankrollAmountDAO:SetText(player1BankingBankrollDAO .. " G")
    
    player1213WinDAO()
end



























-- >>> PLAYER 2 <<<
-- >>> PLAYER 2 <<<
-- >>> PLAYER 2 <<<

-- Bet Amounts
-- "Player 2" titleDAO
player2TitleTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player2TitleTextDAO:SetPoint("CENTER", dealerFrameDAO, -170, 188)
player2TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player2TitleTextDAO:SetJustifyH("CENTER")
player2TitleTextDAO:SetText("Player 2")
-- Player 2 character nameDAO
player2NameTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player2NameTextDAO:SetPoint("CENTER", dealerFrameDAO, -170, 170)
player2NameTextDAO:SetText("Seat Empty")
player2NameTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
-- Player 2 "Main Bet" amount text
player2MainBetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player2MainBetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -170, 151)
player2MainBetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player2MainBetAmountTextDAO:SetJustifyH("CENTER")
player2MainBetAmountTextDAO:SetText("Main Bet: N/A")
player2MainBetAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 2 "Hand 1 Bet" amount text
player2Hand1BetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player2Hand1BetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -206, 151)
player2Hand1BetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player2Hand1BetAmountTextDAO:SetJustifyH("CENTER")
player2Hand1BetAmountTextDAO:SetText("H1: N/A")
player2Hand1BetAmountTextDAO:SetTextColor(1, 1, 1)
player2Hand1BetAmountTextDAO:Hide()
-- Player 2 "Hand 2 Bet" amount text
player2Hand2BetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player2Hand2BetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -134, 151)
player2Hand2BetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player2Hand2BetAmountTextDAO:SetJustifyH("CENTER")
player2Hand2BetAmountTextDAO:SetText("H2: N/A")
player2Hand2BetAmountTextDAO:SetTextColor(1, 1, 1)
player2Hand2BetAmountTextDAO:Hide()
-- Player 2 "Insurance Bet" amount text
player2InsuranceAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player2InsuranceAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -170, 140)
player2InsuranceAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player2InsuranceAmountTextDAO:SetJustifyH("CENTER")
player2InsuranceAmountTextDAO:SetText("Insurance: N/A")
player2InsuranceAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 2 "21+3 Side Bet" amount text
player2213AmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player2213AmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -170, 129)
player2213AmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player2213AmountTextDAO:SetJustifyH("CENTER")
player2213AmountTextDAO:SetText("21+3 Side Bet: N/A")
player2213AmountTextDAO:SetTextColor(1, 1, 1)
-- Player 2 "PP Side Bet" amount text
player2PPAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player2PPAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -170, 118)
player2PPAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player2PPAmountTextDAO:SetJustifyH("CENTER")
player2PPAmountTextDAO:SetText("PP Side Bet: N/A")
player2PPAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 2 "Total Bet" amount text
player2TotalAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player2TotalAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -170, 107)
player2TotalAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player2TotalAmountTextDAO:SetJustifyH("CENTER")
player2TotalAmountTextDAO:SetText("Total: N/A")
player2TotalAmountTextDAO:SetTextColor(1, 1, 0.5)
-- Card Total for Player 2
dealerFrameDAO.player2CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player2CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", -139, 82)
dealerFrameDAO.player2CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player2CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player2CardTotalTextDAO:SetText("")
-- Card Total (Split Hand 1) for Player 1
dealerFrameDAO.player2SplitHand1CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", -167, 71)
dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("")
-- Card Total (Split Hand 2) for Player 1
dealerFrameDAO.player2SplitHand2CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", -112, 92)
dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("")

-- ImagesDAO for Player 2
-- Main Bet
dealerFrameDAO.player2NormalCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2NormalCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2NormalCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -141, 48)
dealerFrameDAO.player2NormalCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player2NormalCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2NormalCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2NormalCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2NormalCoinsDAO:Hide()
-- Split Bet Hand 2
dealerFrameDAO.player2SplitHand2CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2SplitHand2CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2SplitHand2CoinsDAO:SetPoint("CENTER", dealerFrameDAO, -125, 48)
dealerFrameDAO.player2SplitHand2CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player2SplitHand2CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2SplitHand2CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2SplitHand2CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2SplitHand2CoinsDAO:Hide()
-- Split Double Bet Hand 2
dealerFrameDAO.player2SplitHand2DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2SplitHand2DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2SplitHand2DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -125, 48)
dealerFrameDAO.player2SplitHand2DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player2SplitHand2DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2SplitHand2DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2SplitHand2DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2SplitHand2DoubleCoinsDAO:Hide()
-- Split Bet Hand 1
dealerFrameDAO.player2SplitHand1CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2SplitHand1CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2SplitHand1CoinsDAO:SetPoint("CENTER", dealerFrameDAO, -152, 32)
dealerFrameDAO.player2SplitHand1CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player2SplitHand1CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2SplitHand1CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2SplitHand1CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2SplitHand1CoinsDAO:Hide()
-- Split Double Bet Hand 1
dealerFrameDAO.player2SplitHand1DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2SplitHand1DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2SplitHand1DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -152, 32)
dealerFrameDAO.player2SplitHand1DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player2SplitHand1DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2SplitHand1DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2SplitHand1DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2SplitHand1DoubleCoinsDAO:Hide()
-- Double Bet
dealerFrameDAO.player2DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -141, 48)
dealerFrameDAO.player2DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player2DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2DoubleCoinsDAO:Hide()
-- PP Bet
dealerFrameDAO.player2PPCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2PPCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2PPCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -79, 31)
dealerFrameDAO.player2PPCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsHalfBet.tga")
dealerFrameDAO.player2PPCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2PPCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2PPCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2PPCoinsDAO:Hide()
-- 21+3 Bet
dealerFrameDAO.player2213CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2213CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2213CoinsDAO:SetPoint("CENTER", dealerFrameDAO, -160, -7)
dealerFrameDAO.player2213CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsHalfBet.tga")
dealerFrameDAO.player2213CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2213CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2213CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2213CoinsDAO:Hide()
-- Win
dealerFrameDAO.player2NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -141, 48)
dealerFrameDAO.player2NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player2NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2NormalWinCoinsDAO:Hide()
-- Split Win Hand 2
dealerFrameDAO.player2SplitHand2NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2SplitHand2NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2SplitHand2NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -125, 48)
dealerFrameDAO.player2SplitHand2NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player2SplitHand2NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2SplitHand2NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2SplitHand2NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2SplitHand2NormalWinCoinsDAO:Hide()
-- Split Win Hand 1
dealerFrameDAO.player2SplitHand1NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2SplitHand1NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2SplitHand1NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -152, 32)
dealerFrameDAO.player2SplitHand1NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player2SplitHand1NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2SplitHand1NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2SplitHand1NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2SplitHand1NormalWinCoinsDAO:Hide()
-- Blackjack Win
dealerFrameDAO.player2BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -141, 48)
dealerFrameDAO.player2BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player2BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2BJWinCoinsDAO:Hide()
-- Split BJ Win Hand 2
dealerFrameDAO.player2SplitHand2BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2SplitHand2BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2SplitHand2BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -125, 48)
dealerFrameDAO.player2SplitHand2BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player2SplitHand2BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2SplitHand2BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2SplitHand2BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2SplitHand2BJWinCoinsDAO:Hide()
-- Split BJ Win Hand 1
dealerFrameDAO.player2SplitHand1BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2SplitHand1BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2SplitHand1BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -152, 32)
dealerFrameDAO.player2SplitHand1BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player2SplitHand1BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2SplitHand1BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2SplitHand1BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2SplitHand1BJWinCoinsDAO:Hide()
-- PP Win
dealerFrameDAO.player2PPWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2PPWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2PPWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -88, 36)
dealerFrameDAO.player2PPWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player2PPWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2PPWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2PPWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2PPWinCoinsDAO:Hide()
-- 21+3 Win
dealerFrameDAO.player2213WinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player2213WinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player2213WinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -169, -2)
dealerFrameDAO.player2213WinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player2213WinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player2213WinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player2213WinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player2213WinCoinsDAO:Hide()

-- Labels for Player 2
-- Main Bet AmountDAO
dealerFrameDAO.player2MainBetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player2MainBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -123, 75)
dealerFrameDAO.player2MainBetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player2MainBetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Split Hand 1 Bet AmountDAO
dealerFrameDAO.player2SplitHand1LabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player2SplitHand1LabelDAO:SetPoint("CENTER", dealerFrameDAO, -136, 59)
dealerFrameDAO.player2SplitHand1LabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player2SplitHand1LabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Split Hand 2 Bet AmountDAO
dealerFrameDAO.player2SplitHand2LabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player2SplitHand2LabelDAO:SetPoint("CENTER", dealerFrameDAO, -108, 75)
dealerFrameDAO.player2SplitHand2LabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player2SplitHand2LabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Perfect Pairs AmountDAO
dealerFrameDAO.player2PPBetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player2PPBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -71, 49)
dealerFrameDAO.player2PPBetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player2PPBetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- 21+3 AmountDAO
dealerFrameDAO.player2213BetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player2213BetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -151, 11)
dealerFrameDAO.player2213BetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player2213BetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Insurance YES for Player 2
player2InsuranceYesIconDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
player2InsuranceYesIconDAO:SetSize(14, 14)
player2InsuranceYesIconDAO:SetPoint("CENTER", dealerFrameDAO, -207, 189)
player2InsuranceYesIconDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\insuranceYes.tga")
player2InsuranceYesIconDAO:SetDrawLayer("OVERLAY")
player2InsuranceYesIconDAO:Hide()
-- Insurance NO for Player 2
player2InsuranceNoIconDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
player2InsuranceNoIconDAO:SetSize(14, 14)
player2InsuranceNoIconDAO:SetPoint("CENTER", dealerFrameDAO, -207, 189)
player2InsuranceNoIconDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\insuranceNo.tga")
player2InsuranceNoIconDAO:SetDrawLayer("OVERLAY")
player2InsuranceNoIconDAO:Hide()

function player2HandleInsuranceYesDAO(messageDAO)
    player2InsuranceYesIconDAO:Show()
    player2InsuranceBetValueDAO = string.match(messageDAO, "(%d+)G")
    if player2InsuranceBetValueDAO then
        player2InsuranceAmountTextDAO:SetText("Insurance: " .. player2InsuranceBetValueDAO .. " G")
        player2TotalBetAmountDAO = player2TotalBetAmountDAO + player2InsuranceBetValueDAO
        player2TotalAmountTextDAO:SetText("Total: " .. player2TotalBetAmountDAO .. " G")
    end

    player2BankingTotalWageredDAO = player2BankingTotalWageredDAO + tonumber(player2InsuranceBetValueDAO)
    bankingFrameDAO.player2totalWageredAmountDAO:SetText(player2BankingTotalWageredDAO .. " G")

    player2BankingBankrollDAO = player2BankingBankrollDAO - tonumber(player2InsuranceBetValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

end

function player2InsuranceWinDAO(messageDAO)
    player2InsuranceBetAmountValueDAO = tonumber(string.match(player2InsuranceAmountTextDAO:GetText(), "%d+"))
    if player2InsuranceBetAmountValueDAO then
        player2InsuranceWinAmountValueDAO = player2InsuranceBetAmountValueDAO * 3

        player2InsuranceProfitValueDAO = player2InsuranceWinAmountValueDAO - player2InsuranceBetAmountValueDAO

        player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2InsuranceProfitValueDAO)
        bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

        player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2InsuranceProfitValueDAO)
        bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

        if player2BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end
        
        player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2InsuranceWinAmountValueDAO)
        bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

        player2InsuranceAmountTextDAO:SetText("Insurance: " .. player2InsuranceWinAmountValueDAO .. " G")
        player2InsuranceAmountTextDAO:SetTextColor(0, 1, 0)

    end

end

function player2InsuranceLossDAO(messageDAO)
    if player2InsuranceAmountTextDAO:GetText() == "Insurance: N/A" then
        print("")
    else
        player2InsuranceBetAmountValueDAO = tonumber(string.match(player2InsuranceAmountTextDAO:GetText(), "%d+"))
        if player2InsuranceBetAmountValueDAO then

            player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2InsuranceBetAmountValueDAO)
            bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

            player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2InsuranceBetAmountValueDAO)
            bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")
        end
    end
end

function player2HandleInsuranceNoDAO(messageDAO)
    player2InsuranceNoIconDAO:Show()
    player2InsuranceAmountTextDAO:SetText("Insurance: 0 G")
end

-- Player 2 Main Bet Image
function player2PlaceMainBetDAO(messageDAO)
    dealerFrameDAO.player2NormalCoinsDAO:Show()
end

-- Player 2 Main Bet Text
function player2PlaceMainBetTextDAO(AmountDAO)
    dealerFrameDAO.player2MainBetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player2MainBetLabelDAO:Show()
end

-- Player 2 Double Bet Image
function player2PlaceDoubleBetDAO(messageDAO)
    dealerFrameDAO.player2NormalCoinsDAO:Hide()
    dealerFrameDAO.player2DoubleCoinsDAO:Show()
end

-- Player 2 Push
function player2PushDAO(messageDAO)
    player2MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2MainBetLabelDAO:GetText(), "%d+"))
    if player2MainBetAmountValueDAO then

        dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2MainBetAmountValueDAO)
        bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

        local player2PPBetTextDAO = dealerFrameDAO.player2PPBetLabelDAO:GetText()

        if player2PPBetTextDAO and player2PPBetTextDAO ~= "" then
            player2PPBetAmountValueDAO = tonumber(string.match(player2PPBetTextDAO, "%d+"))
            
            if player2PPBetAmountValueDAO then
                if player2PPSideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player2213BetTextDAO = dealerFrameDAO.player2213BetLabelDAO:GetText()

        if player2213BetTextDAO and player2213BetTextDAO ~= "" then
            player2213BetAmountValueDAO = tonumber(string.match(player2213BetTextDAO, "%d+"))

            if player2213BetAmountValueDAO then
                if player2213SideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 2 Split Hand 1 Push
function player2SplitH1PushDAO()
    player2SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1LabelDAO:GetText(), "%d+"))
    if player2SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

    end
end

-- Player 2 Split Hand 2 Push
function player2SplitH2PushDAO()
    player2SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2LabelDAO:GetText(), "%d+"))
    if player2SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

        local player2PPBetTextDAO = dealerFrameDAO.player2PPBetLabelDAO:GetText()

        if player2PPBetTextDAO and player2PPBetTextDAO ~= "" then
            player2PPBetAmountValueDAO = tonumber(string.match(player2PPBetTextDAO, "%d+"))
            
            if player2PPBetAmountValueDAO then
                if player2PPSideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player2213BetTextDAO = dealerFrameDAO.player2213BetLabelDAO:GetText()

        if player2213BetTextDAO and player2213BetTextDAO ~= "" then
            player2213BetAmountValueDAO = tonumber(string.match(player2213BetTextDAO, "%d+"))

            if player2213BetAmountValueDAO then
                if player2213SideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 2 Loss
function player2LossDAO(messageDAO)
    player2MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2MainBetLabelDAO:GetText(), "%d+"))
    if player2MainBetAmountValueDAO then

        dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)

        player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2MainBetAmountValueDAO)
        bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

        player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2MainBetAmountValueDAO)
        bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

        if player2BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player2PPBetTextDAO = dealerFrameDAO.player2PPBetLabelDAO:GetText()

        if player2PPBetTextDAO and player2PPBetTextDAO ~= "" then
            player2PPBetAmountValueDAO = tonumber(string.match(player2PPBetTextDAO, "%d+"))
            
            if player2PPBetAmountValueDAO then
                if player2PPSideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player2213BetTextDAO = dealerFrameDAO.player2213BetLabelDAO:GetText()

        if player2213BetTextDAO and player2213BetTextDAO ~= "" then
            player2213BetAmountValueDAO = tonumber(string.match(player2213BetTextDAO, "%d+"))

            if player2213BetAmountValueDAO then
                if player2213SideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 2 Split Hand 1 Loss
function player2SplitH1LossDAO()
    player2SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1LabelDAO:GetText(), "%d+"))
    if player2SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)

        player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

        player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

        if player2BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

    end

end

-- Player 2 Split Hand 2 Loss
function player2SplitH2LossDAO()
    player2SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2LabelDAO:GetText(), "%d+"))
    if player2SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)

        player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

        player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

        if player2BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player2PPBetTextDAO = dealerFrameDAO.player2PPBetLabelDAO:GetText()

        if player2PPBetTextDAO and player2PPBetTextDAO ~= "" then
            player2PPBetAmountValueDAO = tonumber(string.match(player2PPBetTextDAO, "%d+"))
            
            if player2PPBetAmountValueDAO then
                if player2PPSideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player2213BetTextDAO = dealerFrameDAO.player2213BetLabelDAO:GetText()

        if player2213BetTextDAO and player2213BetTextDAO ~= "" then
            player2213BetAmountValueDAO = tonumber(string.match(player2213BetTextDAO, "%d+"))

            if player2213BetAmountValueDAO then
                if player2213SideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 2 Win
function player2WinDAO(messageDAO)
    player2MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2MainBetLabelDAO:GetText(), "%d+"))
    if player2MainBetAmountValueDAO then

        dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(0, 1, 0)

        player2NormalWinAmountValueDAO = player2MainBetAmountValueDAO * 2
        dealerFrameDAO.player2MainBetLabelDAO:SetText(player2NormalWinAmountValueDAO .. " G")
        player2MainBetAmountTextDAO:SetText("Main Bet: " .. player2NormalWinAmountValueDAO .. " G")

        player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2MainBetAmountValueDAO)
        bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

        player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2MainBetAmountValueDAO)
        bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

        player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2NormalWinAmountValueDAO)
        bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

        if player2BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player2PPBetTextDAO = dealerFrameDAO.player2PPBetLabelDAO:GetText()

        if player2PPBetTextDAO and player2PPBetTextDAO ~= "" then
            player2PPBetAmountValueDAO = tonumber(string.match(player2PPBetTextDAO, "%d+"))

            if player2PPBetAmountValueDAO then
                if player2PPSideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player2213BetTextDAO = dealerFrameDAO.player2213BetLabelDAO:GetText()

        if player2213BetTextDAO and player2213BetTextDAO ~= "" then
            player2213BetAmountValueDAO = tonumber(string.match(player2213BetTextDAO, "%d+"))
            
            if player2213BetAmountValueDAO then
                if player2213SideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

    end
    dealerFrameDAO.player2NormalCoinsDAO:Hide()
    dealerFrameDAO.player2NormalWinCoinsDAO:Show()
end

-- Player 2 Split Hand 1 Win
function player2SplitH1WinDAO(messageDAO)
    player2SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1LabelDAO:GetText(), "%d+"))
    if player2SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(0, 1, 0)

        player2SplitHand1NormalWinAmountValueDAO = player2SplitHand1BetAmountValueDAO * 2
        dealerFrameDAO.player2SplitHand1LabelDAO:SetText(player2SplitHand1NormalWinAmountValueDAO .. " G")
        player2Hand1BetAmountTextDAO:SetText("H1: " .. player2SplitHand1NormalWinAmountValueDAO .. " G")

        player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")
    
        player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")
    
        player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2SplitHand1NormalWinAmountValueDAO)
        bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

        if player2BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

    end

    dealerFrameDAO.player2SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player2SplitHand1NormalWinCoinsDAO:Show()

end

-- Player 2 Split Hand 2 Win
function player2SplitH2WinDAO(messageDAO)
    player2SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2LabelDAO:GetText(), "%d+"))
    if player2SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(0, 1, 0)

        player2SplitHand2NormalWinAmountValueDAO = player2SplitHand2BetAmountValueDAO * 2
        dealerFrameDAO.player2SplitHand2LabelDAO:SetText(player2SplitHand2NormalWinAmountValueDAO .. " G")
        player2Hand2BetAmountTextDAO:SetText("H2: " .. player2SplitHand2NormalWinAmountValueDAO .. " G")

        player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")
    
        player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")
    
        player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2SplitHand2NormalWinAmountValueDAO)
        bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

        if player2BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player2PPBetTextDAO = dealerFrameDAO.player2PPBetLabelDAO:GetText()

        if player2PPBetTextDAO and player2PPBetTextDAO ~= "" then
            player2PPBetAmountValueDAO = tonumber(string.match(player2PPBetTextDAO, "%d+"))

            if player2PPBetAmountValueDAO then
                if player2PPSideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2PPBetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player2213BetTextDAO = dealerFrameDAO.player2213BetLabelDAO:GetText()

        if player2213BetTextDAO and player2213BetTextDAO ~= "" then
            player2213BetAmountValueDAO = tonumber(string.match(player2213BetTextDAO, "%d+"))
            
            if player2213BetAmountValueDAO then
                if player2213SideBetWinDAO == false then

                    player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2213BetAmountValueDAO)
                    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                    if player2BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

    end

    dealerFrameDAO.player2SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player2SplitHand2NormalWinCoinsDAO:Show()

end

-- Player 2 BJ Win
function player2BJWinDAO(messageDAO)
    player2MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2MainBetLabelDAO:GetText(), "%d+"))
    if player2MainBetAmountValueDAO then
        player2BJWinAmountValueDAO = player2MainBetAmountValueDAO * 2.5
        dealerFrameDAO.player2MainBetLabelDAO:SetText(player2BJWinAmountValueDAO .. " G")
        player2MainBetAmountTextDAO:SetText("Main Bet: " .. player2BJWinAmountValueDAO .. " G")
    end

    player2BJProfitvalueDAO = player2BJWinAmountValueDAO - player2MainBetAmountValueDAO

    player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2BJProfitvalueDAO)
    bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2BJProfitvalueDAO)
    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

    player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2BJWinAmountValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

    if player2BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player2PPBetTextDAO = dealerFrameDAO.player2PPBetLabelDAO:GetText()

    if player2PPBetTextDAO and player2PPBetTextDAO ~= "" then
        player2PPBetAmountValueDAO = tonumber(string.match(player2PPBetTextDAO, "%d+"))

        if player2PPBetAmountValueDAO then
            if player2PPSideBetWinDAO == false then

                player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2PPBetAmountValueDAO)
                bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2PPBetAmountValueDAO)
                bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                if player2BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    local player2213BetTextDAO = dealerFrameDAO.player2213BetLabelDAO:GetText()

    if player2213BetTextDAO and player2213BetTextDAO ~= "" then
        player2213BetAmountValueDAO = tonumber(string.match(player2213BetTextDAO, "%d+"))
        
        if player2213BetAmountValueDAO then
            if player2213SideBetWinDAO == false then

                player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2213BetAmountValueDAO)
                bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2213BetAmountValueDAO)
                bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                if player2BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

    dealerFrameDAO.player2NormalCoinsDAO:Hide()
    dealerFrameDAO.player2BJWinCoinsDAO:Show()

end

-- Player 2 Split Hand 1 BJ Win
function player2SplitH1BJDAO(messageDAO)
    player2SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1LabelDAO:GetText(), "%d+"))
    if player2SplitHand1BetAmountValueDAO then
        player2SplitHand1BJWinAmountValueDAO = player2SplitHand1BetAmountValueDAO * 2.5
        dealerFrameDAO.player2SplitHand1LabelDAO:SetText(player2SplitHand1BJWinAmountValueDAO .. " G")
        player2Hand1BetAmountTextDAO:SetText("H1: " .. player2SplitHand1BJWinAmountValueDAO .. " G")
    end

    player2SplitHand1BJProfitValueDAO = player2SplitHand1BJWinAmountValueDAO - player2SplitHand1BetAmountValueDAO

    player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2SplitHand1BJProfitValueDAO)
    bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2SplitHand1BJProfitValueDAO)
    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

    player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2SplitHand1BJWinAmountValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

    if player2BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player2PPBetTextDAO = dealerFrameDAO.player2PPBetLabelDAO:GetText()

    dealerFrameDAO.player2SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player2SplitHand1BJWinCoinsDAO:Show()

end

-- Player 2 Split Hand 2 BJ Win
function player2SplitH2BJDAO(messageDAO)
    player2SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2LabelDAO:GetText(), "%d+"))
    if player2SplitHand2BetAmountValueDAO then
        player2SplitHand2BJWinAmountValueDAO = player2SplitHand2BetAmountValueDAO * 2.5
        dealerFrameDAO.player2SplitHand2LabelDAO:SetText(player2SplitHand2BJWinAmountValueDAO .. " G")
        player2Hand2BetAmountTextDAO:SetText("H2: " .. player2SplitHand2BJWinAmountValueDAO .. " G")
    end

    player2SplitHand2BJProfitValueDAO = player2SplitHand2BJWinAmountValueDAO - player2SplitHand2BetAmountValueDAO

    player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2SplitHand2BJProfitValueDAO)
    bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2SplitHand2BJProfitValueDAO)
    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

    player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2SplitHand2BJWinAmountValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

    if player2BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player2PPBetTextDAO = dealerFrameDAO.player2PPBetLabelDAO:GetText()

    if player2PPBetTextDAO and player2PPBetTextDAO ~= "" then
        player2PPBetAmountValueDAO = tonumber(string.match(player2PPBetTextDAO, "%d+"))

        if player2PPBetAmountValueDAO then
            if player2PPSideBetWinDAO == false then

                player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2PPBetAmountValueDAO)
                bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2PPBetAmountValueDAO)
                bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                if player2BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    local player2213BetTextDAO = dealerFrameDAO.player2213BetLabelDAO:GetText()

    if player2213BetTextDAO and player2213BetTextDAO ~= "" then
        player2213BetAmountValueDAO = tonumber(string.match(player2213BetTextDAO, "%d+"))
        
        if player2213BetAmountValueDAO then
            if player2213SideBetWinDAO == false then

                player2BankingTotalLostDAO = player2BankingTotalLostDAO + tonumber(player2213BetAmountValueDAO)
                bankingFrameDAO.player2totalLostAmountDAO:SetText(player2BankingTotalLostDAO .. " G")

                player2BankingTotalProfitDAO = player2BankingTotalProfitDAO - tonumber(player2213BetAmountValueDAO)
                bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

                if player2BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    dealerFrameDAO.player2SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player2SplitHand2BJWinCoinsDAO:Show()

end

-- Player 2 Main Bet Complete Function
function player2HandleMainBetDAO(messageDAO)
    player2PlaceMainBetDAO()
    player2ActiveDAO = true
    local player2MainBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player2MainBetAmountValueDAO then
            player2PlaceMainBetTextDAO(player2MainBetAmountValueDAO)
            player2MainBetAmountTextDAO:SetText("Main Bet: " .. player2MainBetAmountValueDAO .. " G")
            player2TotalBetAmountDAO = player2TotalBetAmountDAO + tonumber(player2MainBetAmountValueDAO)
            player2TotalAmountTextDAO:SetText("Total: " .. player2TotalBetAmountDAO .. " G")
        else
    end

    player2BankingTotalWageredDAO = player2BankingTotalWageredDAO + tonumber(player2MainBetAmountValueDAO)
    bankingFrameDAO.player2totalWageredAmountDAO:SetText(player2BankingTotalWageredDAO .. " G")

    player2BankingBankrollDAO = player2BankingBankrollDAO - tonumber(player2MainBetAmountValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

end

-- Player 2 Double Bet Complete Function
function player2HandleDoubleBetDAO(messageDAO)
    player2PlaceDoubleBetDAO()
    local player2DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player2OriginalBetAmountValueDAO = tonumber(player2DoubleBetAmountValueDAO) / 2
    if player2DoubleBetAmountValueDAO then
        player2PlaceMainBetTextDAO(player2DoubleBetAmountValueDAO)
        player2MainBetAmountTextDAO:SetText("Main Bet: " .. player2DoubleBetAmountValueDAO .. " G")
        player2TotalBetAmountDAO = player2TotalBetAmountDAO + player2OriginalBetAmountValueDAO
        player2TotalAmountTextDAO:SetText("Total: " .. player2TotalBetAmountDAO .. " G")
    else
    end

    player2BankingTotalWageredDAO = player2BankingTotalWageredDAO + tonumber(player2OriginalBetAmountValueDAO)
    bankingFrameDAO.player2totalWageredAmountDAO:SetText(player2BankingTotalWageredDAO .. " G")

    player2BankingBankrollDAO = player2BankingBankrollDAO - tonumber(player2OriginalBetAmountValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

end

-- Player 2 Split Hand 1 Double Bet Complete Function
function player2SplitHand1DoubleBetDAO(messageDAO)
    
    dealerFrameDAO.player2SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player2SplitHand1DoubleCoinsDAO:Show()

    local player2SplitH1DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player2SplitH1OriginalBetAmountValueDAO = tonumber(player2SplitH1DoubleBetAmountValueDAO) / 2
    if player2SplitH1DoubleBetAmountValueDAO then
        dealerFrameDAO.player2SplitHand1LabelDAO:SetText(player2SplitH1DoubleBetAmountValueDAO .. " G")
        player2Hand1BetAmountTextDAO:SetText("H1: " .. player2SplitH1DoubleBetAmountValueDAO .. " G")
        player2TotalBetAmountDAO = player2TotalBetAmountDAO + player2SplitH1OriginalBetAmountValueDAO
        player2TotalAmountTextDAO:SetText("Total: " .. player2TotalBetAmountDAO .. " G")
    end

    player2BankingTotalWageredDAO = player2BankingTotalWageredDAO + tonumber(player2SplitH1OriginalBetAmountValueDAO)
    bankingFrameDAO.player2totalWageredAmountDAO:SetText(player2BankingTotalWageredDAO .. " G")

    player2BankingBankrollDAO = player2BankingBankrollDAO - tonumber(player2SplitH1OriginalBetAmountValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

end

-- Player 2 Split Hand 2 Double Bet Complete Function
function player2SplitHand2DoubleBetDAO(messageDAO)
    
    dealerFrameDAO.player2SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player2SplitHand2DoubleCoinsDAO:Show()

    local player2SplitH2DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player2SplitH2OriginalBetAmountValueDAO = tonumber(player2SplitH2DoubleBetAmountValueDAO) / 2
    if player2SplitH2DoubleBetAmountValueDAO then
        dealerFrameDAO.player2SplitHand2LabelDAO:SetText(player2SplitH2DoubleBetAmountValueDAO .. " G")
        player2Hand2BetAmountTextDAO:SetText("H2: " .. player2SplitH2DoubleBetAmountValueDAO .. " G")
        player2TotalBetAmountDAO = player2TotalBetAmountDAO + player2SplitH2OriginalBetAmountValueDAO
        player2TotalAmountTextDAO:SetText("Total: " .. player2TotalBetAmountDAO .. " G")
    end

    player2BankingTotalWageredDAO = player2BankingTotalWageredDAO + tonumber(player2SplitH2OriginalBetAmountValueDAO)
    bankingFrameDAO.player2totalWageredAmountDAO:SetText(player2BankingTotalWageredDAO .. " G")

    player2BankingBankrollDAO = player2BankingBankrollDAO - tonumber(player2SplitH2OriginalBetAmountValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

end

-- Player 2 Split Hand Bet Text
function player2SplitHand1BetTextDAO(AmountDAO)
    dealerFrameDAO.player2MainBetLabelDAO:Hide()
    dealerFrameDAO.player2MainBetLabelDAO:SetText("")
    dealerFrameDAO.player2SplitHand1LabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player2SplitHand1LabelDAO:Show()
    dealerFrameDAO.player2SplitHand2LabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player2SplitHand2LabelDAO:Show()
end

-- Player 2 Split Bet Image
function player2PlaceSplitBetDAO(messageDAO)
    dealerFrameDAO.player2NormalCoinsDAO:Hide()
    dealerFrameDAO.player2SplitHand2CoinsDAO:Show()
    dealerFrameDAO.player2SplitHand1CoinsDAO:Show()
end

-- Player 2 Place Initial Card ImagesDAO
function player2PlaceSplitCardsDAO(messageDAO)

    -- Players: 2
    if not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[3]:Hide()
        player2cardName1DAO = dealtCardsDAO[1]
        player2cardName2DAO = dealtCardsDAO[3]
        turnDAO = 8 -- Player 2: 2nd Card (Split H1)

    -- Players: 1, 2
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[2]:Hide()
        cardImagesDAO[5]:Hide()
        player2cardName1DAO = dealtCardsDAO[2]
        player2cardName2DAO = dealtCardsDAO[5]
        turnDAO = 30 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 3
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[4]:Hide()
        player2cardName1DAO = dealtCardsDAO[1]
        player2cardName2DAO = dealtCardsDAO[4]
        turnDAO = 10 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 4
    elseif not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[4]:Hide()
        player2cardName1DAO = dealtCardsDAO[1]
        player2cardName2DAO = dealtCardsDAO[4]
        turnDAO = 10 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 5
    elseif not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[4]:Hide()
        player2cardName1DAO = dealtCardsDAO[1]
        player2cardName2DAO = dealtCardsDAO[4]
        turnDAO = 10 -- Player 2: 2nd Card (Split H1)
        
    -- Players: 1, 2, 3
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[6]:Hide()
        player2cardName1DAO = dealtCardsDAO[2]
        player2cardName2DAO = dealtCardsDAO[6]
        turnDAO = 32 -- Player 2: 2nd Card (Split H1)
    -- Players: 1, 2, 4
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[6]:Hide()
        player2cardName1DAO = dealtCardsDAO[2]
        player2cardName2DAO = dealtCardsDAO[6]
        turnDAO = 32 -- Player 2: 2nd Card (Split H1)
    -- Players: 1, 2, 5
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[6]:Hide()
        player2cardName1DAO = dealtCardsDAO[2]
        player2cardName2DAO = dealtCardsDAO[6]
        turnDAO = 32 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 3, 4
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[5]:Hide()
        player2cardName1DAO = dealtCardsDAO[1]
        player2cardName2DAO = dealtCardsDAO[5]
        turnDAO = 12 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 3, 5
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[5]:Hide()
        player2cardName1DAO = dealtCardsDAO[1]
        player2cardName2DAO = dealtCardsDAO[5]
        turnDAO = 12 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 4, 5
    elseif not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[5]:Hide()
        player2cardName1DAO = dealtCardsDAO[1]
        player2cardName2DAO = dealtCardsDAO[5]
        turnDAO = 12 -- Player 2: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[7]:Hide()
        player2cardName1DAO = dealtCardsDAO[2]
        player2cardName2DAO = dealtCardsDAO[7]
        turnDAO = 34 -- Player 2: 2nd Card (Split H1)
    -- Players: 1, 2, 3, 5
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[7]:Hide()
        player2cardName1DAO = dealtCardsDAO[2]
        player2cardName2DAO = dealtCardsDAO[7]
        turnDAO = 34 -- Player 2: 2nd Card (Split H1)
    -- Players: 1, 2, 4, 5
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[7]:Hide()
        player2cardName1DAO = dealtCardsDAO[2]
        player2cardName2DAO = dealtCardsDAO[7]
        turnDAO = 34 -- Player 2: 2nd Card (Split H1)
    -- Players: 2, 3, 4, 5
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[6]:Hide()
        player2cardName1DAO = dealtCardsDAO[1]
        player2cardName2DAO = dealtCardsDAO[6]
        turnDAO = 14 -- Player 2: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4, 5
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[8]:Hide()
        player2cardName1DAO = dealtCardsDAO[2]
        player2cardName2DAO = dealtCardsDAO[8]
        turnDAO = 36 -- Player 2: 2nd Card (Split H1)

    end

    player2cardImageFile1DAO = nil
    player2cardImageFile2DAO = nil

    for filenameDAO, cardDescriptionDAO in pairs(cardNamesDAO) do
        if cardDescriptionDAO == player2cardName1DAO then
            player2cardImageFile1DAO = filenameDAO
            break
        end
    end

    for filenameDAO, cardDescriptionDAO in pairs(cardNamesDAO) do
        if cardDescriptionDAO == player2cardName2DAO then
            player2cardImageFile2DAO = filenameDAO
            break
        end
    end

    player2NewCardImage1DAO = CreateFrame("Frame", nil, dealerFrameDAO)
    player2NewCardImage1DAO:SetSize(24, 48)
    player2NewCardImage1DAO:SetPoint("CENTER", dealerFrameDAO, -120, -18)
    player2NewCardImage1DAO.texture = player2NewCardImage1DAO:CreateTexture()
    player2NewCardImage1DAO.texture:SetAllPoints()
    player2NewCardImage1DAO.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. player2cardImageFile1DAO)
    player2NewCardImage1DAO:Show()

    player2NewCardImage2DAO = CreateFrame("Frame", nil, dealerFrameDAO)
    player2NewCardImage2DAO:SetSize(24, 48)
    player2NewCardImage2DAO:SetPoint("CENTER", dealerFrameDAO, -88, -9)
    player2NewCardImage2DAO.texture = player2NewCardImage2DAO:CreateTexture()
    player2NewCardImage2DAO.texture:SetAllPoints()
    player2NewCardImage2DAO.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. player2cardImageFile2DAO)
    player2NewCardImage2DAO:Show()

end

-- Player 2 Split Function
function player2HandleSplitDAO(messageDAO)
    player2PlaceSplitBetDAO()
    local player2MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player2MainBetLabelDAO:GetText(), "%d+"))
    if player2MainBetAmountValueDAO then
        player2SplitHand1BetTextDAO(player2MainBetAmountValueDAO)
        player2MainBetAmountTextDAO:Hide()
        player2Hand1BetAmountTextDAO:Show()
        player2Hand2BetAmountTextDAO:Show()
        player2Hand1BetAmountTextDAO:SetText("H1: " .. player2MainBetAmountValueDAO .. " G")
        player2Hand2BetAmountTextDAO:SetText("H2: " .. player2MainBetAmountValueDAO .. " G")
        player2TotalBetAmountDAO = player2TotalBetAmountDAO + player2MainBetAmountValueDAO
        player2TotalAmountTextDAO:SetText("Total: " .. player2TotalBetAmountDAO .. " G")
    else
    end 

    dealerFrameDAO.player2CardTotalTextDAO:SetText("")
    dealerFrameDAO.player2CardTotalTextDAO:Hide()

    if player2RunningTotalDAO == 2 then
        dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("1 or 11")
        dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("1 or 11")
        dealerFrameDAO.player2SplitHand1CardTotalTextDAO:Show()
        dealerFrameDAO.player2SplitHand2CardTotalTextDAO:Show()
    else
        dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText(player2S1RunningTotalDAO)
        dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText(player2S2RunningTotalDAO)
        dealerFrameDAO.player2SplitHand1CardTotalTextDAO:Show()
        dealerFrameDAO.player2SplitHand2CardTotalTextDAO:Show()
    end

    player2BankingTotalWageredDAO = player2BankingTotalWageredDAO + tonumber(player2MainBetAmountValueDAO)
    bankingFrameDAO.player2totalWageredAmountDAO:SetText(player2BankingTotalWageredDAO .. " G")

    player2BankingBankrollDAO = player2BankingBankrollDAO - tonumber(player2MainBetAmountValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")
    
    player2PlaceSplitCardsDAO()

end

-- Player 2 PP Bet Image
function player2PlacePPBetDAO(messageDAO)
    dealerFrameDAO.player2PPCoinsDAO:Show()
end

-- Player 2 PP Bet Text
function player2PlacePPBetTextDAO(AmountDAO)
    dealerFrameDAO.player2PPBetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player2PPBetLabelDAO:Show()
end

-- Player 2 PP Win
function player2PPWinDAO(messageDAO)
    dealerFrameDAO.player2PPCoinsDAO:Hide()
    dealerFrameDAO.player2PPWinCoinsDAO:Show()
    dealerFrameDAO.player2PPBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -71, 63)
end

-- Player 2 PP Bet Complete Function
function player2HandlePPBetDAO(messageDAO)
    player2PlacePPBetDAO()
    local player2PPBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player2PPBetAmountValueDAO then
            player2PlacePPBetTextDAO(player2PPBetAmountValueDAO)
            player2PPAmountTextDAO:SetText("PP Side Bet: " .. player2PPBetAmountValueDAO .. " G")
            player2TotalBetAmountDAO = player2TotalBetAmountDAO + tonumber(player2PPBetAmountValueDAO)
            player2TotalAmountTextDAO:SetText("Total: " .. player2TotalBetAmountDAO .. " G")
        else
    end

    player2BankingTotalWageredDAO = player2BankingTotalWageredDAO + tonumber(player2PPBetAmountValueDAO)
    bankingFrameDAO.player2totalWageredAmountDAO:SetText(player2BankingTotalWageredDAO .. " G")

    player2BankingBankrollDAO = player2BankingBankrollDAO - tonumber(player2PPBetAmountValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

end

-- Player 2 21+3 Bet Image
function player2Place213BetDAO(messageDAO)
    dealerFrameDAO.player2213CoinsDAO:Show()
end

-- Player 2 21+3 Bet Text
function player2Place213BetTextDAO(AmountDAO)
    dealerFrameDAO.player2213BetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player2213BetLabelDAO:Show()
end

-- Player 2 21+3 Win
function player2213WinDAO(messageDAO)
    dealerFrameDAO.player2213CoinsDAO:Hide()
    dealerFrameDAO.player2213WinCoinsDAO:Show()
    dealerFrameDAO.player2213BetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -151, 25)
end

-- Player 2 21+3 Bet Complete Function
function player2Handle213BetDAO(messageDAO)
    player2Place213BetDAO()
    local player2213BetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player2213BetAmountValueDAO then
            player2Place213BetTextDAO(player2213BetAmountValueDAO)
            player2213AmountTextDAO:SetText("21+3 Side Bet: " .. player2213BetAmountValueDAO .. " G")
            player2TotalBetAmountDAO = player2TotalBetAmountDAO + tonumber(player2213BetAmountValueDAO)
            player2TotalAmountTextDAO:SetText("Total: " .. player2TotalBetAmountDAO .. " G")
        else
    end

    player2BankingTotalWageredDAO = player2BankingTotalWageredDAO + tonumber(player2213BetAmountValueDAO)
    bankingFrameDAO.player2totalWageredAmountDAO:SetText(player2BankingTotalWageredDAO .. " G")

    player2BankingBankrollDAO = player2BankingBankrollDAO - tonumber(player2213BetAmountValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

end

function player2MixedPairWinDAO(messageDAO)
    player2PPSideBetWinDAO = true
    player2PPAmountTextValueDAO = tonumber(string.match(player2PPAmountTextDAO:GetText(), "%d+"))
    if player2PPAmountTextValueDAO then
        player2PPWinValueDAO = player2PPAmountTextValueDAO * mixedPairPayoutReturnDAO
        player2PPAmountTextDAO:SetText("PP Side Bet: " .. player2PPWinValueDAO .. " G")
        player2PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player2PPBetLabelDAO:SetText(player2PPWinValueDAO .. " G")
    end

    player2PPProfitValueDAO = player2PPWinValueDAO - player2PPAmountTextValueDAO

    player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2PPProfitValueDAO)
    bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2PPProfitValueDAO)
    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

    if player2BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2PPWinValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

    player2PPWinDAO()
end

function player2ColouredPairWinDAO(messageDAO)
    player2PPSideBetWinDAO = true
    player2PPAmountTextValueDAO = tonumber(string.match(player2PPAmountTextDAO:GetText(), "%d+"))
    if player2PPAmountTextValueDAO then
        player2PPWinValueDAO = player2PPAmountTextValueDAO * colouredPairPayoutReturnDAO
        player2PPAmountTextDAO:SetText("PP Side Bet: " .. player2PPWinValueDAO .. " G")
        player2PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player2PPBetLabelDAO:SetText(player2PPWinValueDAO .. " G")
    end

    player2PPProfitValueDAO = player2PPWinValueDAO - player2PPAmountTextValueDAO

    player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2PPProfitValueDAO)
    bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2PPProfitValueDAO)
    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

    if player2BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2PPWinValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

    player2PPWinDAO()
end

function player2PerfectPairWinDAO(messageDAO)
    player2PPSideBetWinDAO = true
    player2PPAmountTextValueDAO = tonumber(string.match(player2PPAmountTextDAO:GetText(), "%d+"))
    if player2PPAmountTextValueDAO then
        player2PPWinValueDAO = player2PPAmountTextValueDAO * perfectPairPayoutReturnDAO
        player2PPAmountTextDAO:SetText("PP Side Bet: " .. player2PPWinValueDAO .. " G")
        player2PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player2PPBetLabelDAO:SetText(player2PPWinValueDAO .. " G")
    end

    player2PPProfitValueDAO = player2PPWinValueDAO - player2PPAmountTextValueDAO

    player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2PPProfitValueDAO)
    bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2PPProfitValueDAO)
    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

    if player2BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2PPWinValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

    player2PPWinDAO()
end

function player2SuitedThreeOfAKindWinDAO(messageDAO)
    player2213SideBetWinDAO = true
    player2213AmountTextValueDAO = tonumber(string.match(player2213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player2213AmountTextValueDAO then
        player2213WinValueDAO = player2213AmountTextValueDAO * suitedThreeOfAKindPayoutReturnDAO
        player2213AmountTextDAO:SetText("21+3 Side Bet: " .. player2213WinValueDAO .. " G")
        player2213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player2213BetLabelDAO:SetText(player2213WinValueDAO .. " G")
    end

    player2213ProfitValueDAO = player2213WinValueDAO - player2213AmountTextValueDAO

    player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2213ProfitValueDAO)
    bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2213ProfitValueDAO)
    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

    if player2BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2213WinValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

    player2213WinDAO()
end

function player2StraightFlushWinDAO(messageDAO)
    player2213SideBetWinDAO = true
    player2213AmountTextValueDAO = tonumber(string.match(player2213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player2213AmountTextValueDAO then
        player2213WinValueDAO = player2213AmountTextValueDAO * straightFlushPayoutReturnDAO
        player2213AmountTextDAO:SetText("21+3 Side Bet: " .. player2213WinValueDAO .. " G")
        player2213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player2213BetLabelDAO:SetText(player2213WinValueDAO .. " G")
    end

    player2213ProfitValueDAO = player2213WinValueDAO - player2213AmountTextValueDAO

    player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2213ProfitValueDAO)
    bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2213ProfitValueDAO)
    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

    if player2BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2213WinValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

    player2213WinDAO()
end

function player2ThreeOfAKindWinDAO(messageDAO)
    player2213SideBetWinDAO = true
    player2213AmountTextValueDAO = tonumber(string.match(player2213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player2213AmountTextValueDAO then
        player2213WinValueDAO = player2213AmountTextValueDAO * threeOfAKindPayoutReturnDAO
        player2213AmountTextDAO:SetText("21+3 Side Bet: " .. player2213WinValueDAO .. " G")
        player2213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player2213BetLabelDAO:SetText(player2213WinValueDAO .. " G")
    end

    player2213ProfitValueDAO = player2213WinValueDAO - player2213AmountTextValueDAO

    player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2213ProfitValueDAO)
    bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2213ProfitValueDAO)
    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

    if player2BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2213WinValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

    player2213WinDAO()
end

function player2StraightWinDAO(messageDAO)
    player2213SideBetWinDAO = true
    player2213AmountTextValueDAO = tonumber(string.match(player2213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player2213AmountTextValueDAO then
        player2213WinValueDAO = player2213AmountTextValueDAO * straightPayoutReturnDAO
        player2213AmountTextDAO:SetText("21+3 Side Bet: " .. player2213WinValueDAO .. " G")
        player2213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player2213BetLabelDAO:SetText(player2213WinValueDAO .. " G")
    end

    player2213ProfitValueDAO = player2213WinValueDAO - player2213AmountTextValueDAO

    player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2213ProfitValueDAO)
    bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2213ProfitValueDAO)
    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

    if player2BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2213WinValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")

    player2213WinDAO()
end

function player2FlushWinDAO(messageDAO)
    player2213SideBetWinDAO = true
    player2213AmountTextValueDAO = tonumber(string.match(player2213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player2213AmountTextValueDAO then
        player2213WinValueDAO = player2213AmountTextValueDAO * flushPayoutReturnDAO
        player2213AmountTextDAO:SetText("21+3 Side Bet: " .. player2213WinValueDAO .. " G")
        player2213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player2213BetLabelDAO:SetText(player2213WinValueDAO .. " G")
    end

    player2213ProfitValueDAO = player2213WinValueDAO - player2213AmountTextValueDAO

    player2BankingTotalWonDAO = player2BankingTotalWonDAO + tonumber(player2213ProfitValueDAO)
    bankingFrameDAO.player2totalWonAmountDAO:SetText(player2BankingTotalWonDAO .. " G")

    player2BankingTotalProfitDAO = player2BankingTotalProfitDAO + tonumber(player2213ProfitValueDAO)
    bankingFrameDAO.player2totalProfitAmountDAO:SetText(player2BankingTotalProfitDAO .. " G")

    if player2BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player2totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player2BankingBankrollDAO = player2BankingBankrollDAO + tonumber(player2213WinValueDAO)
    bankingFrameDAO.player2BankrollAmountDAO:SetText(player2BankingBankrollDAO .. " G")
    
    player2213WinDAO()
end

























-- >>> PLAYER 3 <<<
-- >>> PLAYER 3 <<<
-- >>> PLAYER 3 <<<

-- Bet Amounts
-- "Player 3" titleDAO
player3TitleTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player3TitleTextDAO:SetPoint("CENTER", dealerFrameDAO, 17, 223)
player3TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player3TitleTextDAO:SetJustifyH("CENTER")
player3TitleTextDAO:SetText("Player 3")
-- Player 3 character nameDAO
player3NameTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player3NameTextDAO:SetPoint("CENTER", dealerFrameDAO, 17, 205)
player3NameTextDAO:SetText("Seat Empty")
player3NameTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
-- Player 3 "Main Bet" amount text
player3MainBetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player3MainBetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 17, 186)
player3MainBetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player3MainBetAmountTextDAO:SetJustifyH("CENTER")
player3MainBetAmountTextDAO:SetText("Main Bet: N/A")
player3MainBetAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 3 "Hand 1 Bet" amount text
player3Hand1BetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player3Hand1BetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, -19, 186)
player3Hand1BetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player3Hand1BetAmountTextDAO:SetJustifyH("CENTER")
player3Hand1BetAmountTextDAO:SetText("H1: N/A")
player3Hand1BetAmountTextDAO:SetTextColor(1, 1, 1)
player3Hand1BetAmountTextDAO:Hide()
-- Player 3 "Hand 2 Bet" amount text
player3Hand2BetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player3Hand2BetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 53, 186)
player3Hand2BetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player3Hand2BetAmountTextDAO:SetJustifyH("CENTER")
player3Hand2BetAmountTextDAO:SetText("H2: N/A")
player3Hand2BetAmountTextDAO:SetTextColor(1, 1, 1)
player3Hand2BetAmountTextDAO:Hide()
-- Player 3 "Insurance Bet" amount text
player3InsuranceAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player3InsuranceAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 17, 175)
player3InsuranceAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player3InsuranceAmountTextDAO:SetJustifyH("CENTER")
player3InsuranceAmountTextDAO:SetText("Insurance: N/A")
player3InsuranceAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 3 "21+3 Side Bet" amount text
player3213AmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player3213AmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 17, 164)
player3213AmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player3213AmountTextDAO:SetJustifyH("CENTER")
player3213AmountTextDAO:SetText("21+3 Side Bet: N/A")
player3213AmountTextDAO:SetTextColor(1, 1, 1)
-- Player 3 "PP Side Bet" amount text
player3PPAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player3PPAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 17, 153)
player3PPAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player3PPAmountTextDAO:SetJustifyH("CENTER")
player3PPAmountTextDAO:SetText("PP Side Bet: N/A")
player3PPAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 3 "Total Bet" amount text
player3TotalAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player3TotalAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 17, 142)
player3TotalAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player3TotalAmountTextDAO:SetJustifyH("CENTER")
player3TotalAmountTextDAO:SetText("Total: N/A")
player3TotalAmountTextDAO:SetTextColor(1, 1, 0.5)
-- Card Total for Player 3
dealerFrameDAO.player3CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player3CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", 13, 116)
dealerFrameDAO.player3CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player3CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player3CardTotalTextDAO:SetText("")
-- Card Total (Split Hand 1) for Player 3
dealerFrameDAO.player3SplitHand1CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", -25, 116)
dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("")
-- Card Total (Split Hand 2) for Player 3
dealerFrameDAO.player3SplitHand2CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", 53, 116)
dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("")

-- ImagesDAO for Player 3
-- Main Bet
dealerFrameDAO.player3NormalCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3NormalCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3NormalCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -6, 73)
dealerFrameDAO.player3NormalCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player3NormalCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3NormalCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3NormalCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3NormalCoinsDAO:Hide()
-- Split Bet Hand 2
dealerFrameDAO.player3SplitHand2CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3SplitHand2CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3SplitHand2CoinsDAO:SetPoint("CENTER", dealerFrameDAO, 16, 73)
dealerFrameDAO.player3SplitHand2CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player3SplitHand2CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3SplitHand2CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3SplitHand2CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3SplitHand2CoinsDAO:Hide()
-- Split Double Bet Hand 2
dealerFrameDAO.player3SplitHand2DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3SplitHand2DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3SplitHand2DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 16, 73)
dealerFrameDAO.player3SplitHand2DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player3SplitHand2DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3SplitHand2DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3SplitHand2DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3SplitHand2DoubleCoinsDAO:Hide()
-- Split Bet Hand 1
dealerFrameDAO.player3SplitHand1CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3SplitHand1CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3SplitHand1CoinsDAO:SetPoint("CENTER", dealerFrameDAO, -24, 73)
dealerFrameDAO.player3SplitHand1CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player3SplitHand1CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3SplitHand1CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3SplitHand1CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3SplitHand1CoinsDAO:Hide()
-- Split Double Bet Hand 1
dealerFrameDAO.player3SplitHand1DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3SplitHand1DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3SplitHand1DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -24, 73)
dealerFrameDAO.player3SplitHand1DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player3SplitHand1DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3SplitHand1DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3SplitHand1DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3SplitHand1DoubleCoinsDAO:Hide()
-- Double Bet
dealerFrameDAO.player3DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -6, 73)
dealerFrameDAO.player3DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player3DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3DoubleCoinsDAO:Hide()
-- PP Bet
dealerFrameDAO.player3PPCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3PPCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3PPCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 48, 41)
dealerFrameDAO.player3PPCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsHalfBet.tga")
dealerFrameDAO.player3PPCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3PPCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3PPCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3PPCoinsDAO:Hide()
-- 21+3 Bet
dealerFrameDAO.player3213CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3213CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3213CoinsDAO:SetPoint("CENTER", dealerFrameDAO, -39, 41)
dealerFrameDAO.player3213CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsHalfBet.tga")
dealerFrameDAO.player3213CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3213CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3213CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3213CoinsDAO:Hide()
-- Win
dealerFrameDAO.player3NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -6, 73)
dealerFrameDAO.player3NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player3NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3NormalWinCoinsDAO:Hide()
-- Split Win Hand 2
dealerFrameDAO.player3SplitHand2NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3SplitHand2NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3SplitHand2NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 16, 73)
dealerFrameDAO.player3SplitHand2NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player3SplitHand2NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3SplitHand2NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3SplitHand2NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3SplitHand2NormalWinCoinsDAO:Hide()
-- Split Win Hand 1
dealerFrameDAO.player3SplitHand1NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3SplitHand1NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3SplitHand1NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -24, 73)
dealerFrameDAO.player3SplitHand1NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player3SplitHand1NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3SplitHand1NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3SplitHand1NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3SplitHand1NormalWinCoinsDAO:Hide()
-- Blackjack Win
dealerFrameDAO.player3BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -6, 73)
dealerFrameDAO.player3BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player3BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3BJWinCoinsDAO:Hide()
-- Split BJ Win Hand 2
dealerFrameDAO.player3SplitHand2BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3SplitHand2BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3SplitHand2BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 16, 73)
dealerFrameDAO.player3SplitHand2BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player3SplitHand2BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3SplitHand2BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3SplitHand2BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3SplitHand2BJWinCoinsDAO:Hide()
-- Split BJ Win Hand 1
dealerFrameDAO.player3SplitHand1BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3SplitHand1BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3SplitHand1BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -24, 73)
dealerFrameDAO.player3SplitHand1BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player3SplitHand1BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3SplitHand1BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3SplitHand1BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3SplitHand1BJWinCoinsDAO:Hide()
-- PP Win
dealerFrameDAO.player3PPWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3PPWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3PPWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 39, 45)
dealerFrameDAO.player3PPWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player3PPWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3PPWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3PPWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3PPWinCoinsDAO:Hide()
-- 21+3 Win
dealerFrameDAO.player3213WinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player3213WinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player3213WinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, -48, 46)
dealerFrameDAO.player3213WinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player3213WinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player3213WinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player3213WinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player3213WinCoinsDAO:Hide()

-- Labels for Player 3
-- Main Bet AmountDAO
dealerFrameDAO.player3MainBetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player3MainBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 11, 100)
dealerFrameDAO.player3MainBetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player3MainBetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Split Hand 1 Bet AmountDAO
dealerFrameDAO.player3SplitHand1LabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player3SplitHand1LabelDAO:SetPoint("CENTER", dealerFrameDAO, -7, 99)
dealerFrameDAO.player3SplitHand1LabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player3SplitHand1LabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Split Hand 2 Bet AmountDAO
dealerFrameDAO.player3SplitHand2LabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player3SplitHand2LabelDAO:SetPoint("CENTER", dealerFrameDAO, 34, 99)
dealerFrameDAO.player3SplitHand2LabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player3SplitHand2LabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Perfect Pairs AmountDAO
dealerFrameDAO.player3PPBetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player3PPBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 57, 59)
dealerFrameDAO.player3PPBetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player3PPBetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- 21+3 AmountDAO
dealerFrameDAO.player3213BetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player3213BetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -31, 59)
dealerFrameDAO.player3213BetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player3213BetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Insurance YES for Player 3
player3InsuranceYesIconDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
player3InsuranceYesIconDAO:SetSize(14, 14)
player3InsuranceYesIconDAO:SetPoint("CENTER", dealerFrameDAO, -18, 222)
player3InsuranceYesIconDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\insuranceYes.tga")
player3InsuranceYesIconDAO:SetDrawLayer("OVERLAY")
player3InsuranceYesIconDAO:Hide()
-- Insurance NO for Player 3
player3InsuranceNoIconDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
player3InsuranceNoIconDAO:SetSize(14, 14)
player3InsuranceNoIconDAO:SetPoint("CENTER", dealerFrameDAO, -18, 222)
player3InsuranceNoIconDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\insuranceNo.tga")
player3InsuranceNoIconDAO:SetDrawLayer("OVERLAY")
player3InsuranceNoIconDAO:Hide()

function player3HandleInsuranceYesDAO(messageDAO)
    player3InsuranceYesIconDAO:Show()
    player3InsuranceBetValueDAO = string.match(messageDAO, "(%d+)G")
    if player3InsuranceBetValueDAO then
        player3InsuranceAmountTextDAO:SetText("Insurance: " .. player3InsuranceBetValueDAO .. " G")
        player3TotalBetAmountDAO = player3TotalBetAmountDAO + player3InsuranceBetValueDAO
        player3TotalAmountTextDAO:SetText("Total: " .. player3TotalBetAmountDAO .. " G")
    end

    player3BankingTotalWageredDAO = player3BankingTotalWageredDAO + tonumber(player3InsuranceBetValueDAO)
    bankingFrameDAO.player3totalWageredAmountDAO:SetText(player3BankingTotalWageredDAO .. " G")

    player3BankingBankrollDAO = player3BankingBankrollDAO - tonumber(player3InsuranceBetValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

end

function player3InsuranceWinDAO(messageDAO)
    player3InsuranceBetAmountValueDAO = tonumber(string.match(player3InsuranceAmountTextDAO:GetText(), "%d+"))
    if player3InsuranceBetAmountValueDAO then
        player3InsuranceWinAmountValueDAO = player3InsuranceBetAmountValueDAO * 3

        player3InsuranceProfitValueDAO = player3InsuranceWinAmountValueDAO - player3InsuranceBetAmountValueDAO

        player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3InsuranceProfitValueDAO)
        bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

        player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3InsuranceProfitValueDAO)
        bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

        if player3BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end
        
        player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3InsuranceWinAmountValueDAO)
        bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

        player3InsuranceAmountTextDAO:SetText("Insurance: " .. player3InsuranceWinAmountValueDAO .. " G")
        player3InsuranceAmountTextDAO:SetTextColor(0, 1, 0)

    end

end

function player3InsuranceLossDAO(messageDAO)
    if player3InsuranceAmountTextDAO:GetText() == "Insurance: N/A" then
        print("")
    else
        player3InsuranceBetAmountValueDAO = tonumber(string.match(player3InsuranceAmountTextDAO:GetText(), "%d+"))
        if player3InsuranceBetAmountValueDAO then

            player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3InsuranceBetAmountValueDAO)
            bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

            player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3InsuranceBetAmountValueDAO)
            bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")
        end
    end
end

function player3HandleInsuranceNoDAO(messageDAO)
    player3InsuranceNoIconDAO:Show()
    player3InsuranceAmountTextDAO:SetText("Insurance: 0 G")
end

-- Player 3 Main Bet Image
function player3PlaceMainBetDAO(messageDAO)
    dealerFrameDAO.player3NormalCoinsDAO:Show()
end

-- Player 3 Main Bet Text
function player3PlaceMainBetTextDAO(AmountDAO)
    dealerFrameDAO.player3MainBetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player3MainBetLabelDAO:Show()
end

-- Player 3 Double Bet Image
function player3PlaceDoubleBetDAO(messageDAO)
    dealerFrameDAO.player3NormalCoinsDAO:Hide()
    dealerFrameDAO.player3DoubleCoinsDAO:Show()
end

-- Player 3 Push
function player3PushDAO(messageDAO)
    player3MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3MainBetLabelDAO:GetText(), "%d+"))
    if player3MainBetAmountValueDAO then

        dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3MainBetAmountValueDAO)
        bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

        local player3PPBetTextDAO = dealerFrameDAO.player3PPBetLabelDAO:GetText()

        if player3PPBetTextDAO and player3PPBetTextDAO ~= "" then
            player3PPBetAmountValueDAO = tonumber(string.match(player3PPBetTextDAO, "%d+"))
            
            if player3PPBetAmountValueDAO then
                if player3PPSideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player3213BetTextDAO = dealerFrameDAO.player3213BetLabelDAO:GetText()

        if player3213BetTextDAO and player3213BetTextDAO ~= "" then
            player3213BetAmountValueDAO = tonumber(string.match(player3213BetTextDAO, "%d+"))

            if player3213BetAmountValueDAO then
                if player3213SideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 3 Split Hand 1 Push
function player3SplitH1PushDAO()
    player3SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1LabelDAO:GetText(), "%d+"))
    if player3SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

    end
end

-- Player 3 Split Hand 2 Push
function player3SplitH2PushDAO()
    player3SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2LabelDAO:GetText(), "%d+"))
    if player3SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

        local player3PPBetTextDAO = dealerFrameDAO.player3PPBetLabelDAO:GetText()

        if player3PPBetTextDAO and player3PPBetTextDAO ~= "" then
            player3PPBetAmountValueDAO = tonumber(string.match(player3PPBetTextDAO, "%d+"))
            
            if player3PPBetAmountValueDAO then
                if player3PPSideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player3213BetTextDAO = dealerFrameDAO.player3213BetLabelDAO:GetText()

        if player3213BetTextDAO and player3213BetTextDAO ~= "" then
            player3213BetAmountValueDAO = tonumber(string.match(player3213BetTextDAO, "%d+"))

            if player3213BetAmountValueDAO then
                if player3213SideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 3 Loss
function player3LossDAO(messageDAO)
    player3MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3MainBetLabelDAO:GetText(), "%d+"))
    if player3MainBetAmountValueDAO then

        dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)

        player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3MainBetAmountValueDAO)
        bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

        player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3MainBetAmountValueDAO)
        bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

        if player3BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player3PPBetTextDAO = dealerFrameDAO.player3PPBetLabelDAO:GetText()

        if player3PPBetTextDAO and player3PPBetTextDAO ~= "" then
            player3PPBetAmountValueDAO = tonumber(string.match(player3PPBetTextDAO, "%d+"))
            
            if player3PPBetAmountValueDAO then
                if player3PPSideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player3213BetTextDAO = dealerFrameDAO.player3213BetLabelDAO:GetText()

        if player3213BetTextDAO and player3213BetTextDAO ~= "" then
            player3213BetAmountValueDAO = tonumber(string.match(player3213BetTextDAO, "%d+"))

            if player3213BetAmountValueDAO then
                if player3213SideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 3 Split Hand 1 Loss
function player3SplitH1LossDAO()
    player3SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1LabelDAO:GetText(), "%d+"))
    if player3SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)

        player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

        player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

        if player3BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

    end

end

-- Player 3 Split Hand 2 Loss
function player3SplitH2LossDAO()
    player3SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2LabelDAO:GetText(), "%d+"))
    if player3SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)

        player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

        player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

        if player3BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player3PPBetTextDAO = dealerFrameDAO.player3PPBetLabelDAO:GetText()

        if player3PPBetTextDAO and player3PPBetTextDAO ~= "" then
            player3PPBetAmountValueDAO = tonumber(string.match(player3PPBetTextDAO, "%d+"))
            
            if player3PPBetAmountValueDAO then
                if player3PPSideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player3213BetTextDAO = dealerFrameDAO.player3213BetLabelDAO:GetText()

        if player3213BetTextDAO and player3213BetTextDAO ~= "" then
            player3213BetAmountValueDAO = tonumber(string.match(player3213BetTextDAO, "%d+"))

            if player3213BetAmountValueDAO then
                if player3213SideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 3 Win
function player3WinDAO(messageDAO)
    player3MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3MainBetLabelDAO:GetText(), "%d+"))
    if player3MainBetAmountValueDAO then

        dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(0, 1, 0)

        player3NormalWinAmountValueDAO = player3MainBetAmountValueDAO * 2
        dealerFrameDAO.player3MainBetLabelDAO:SetText(player3NormalWinAmountValueDAO .. " G")
        player3MainBetAmountTextDAO:SetText("Main Bet: " .. player3NormalWinAmountValueDAO .. " G")

        player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3MainBetAmountValueDAO)
        bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

        player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3MainBetAmountValueDAO)
        bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

        player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3NormalWinAmountValueDAO)
        bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

        if player3BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player3PPBetTextDAO = dealerFrameDAO.player3PPBetLabelDAO:GetText()

        if player3PPBetTextDAO and player3PPBetTextDAO ~= "" then
            player3PPBetAmountValueDAO = tonumber(string.match(player3PPBetTextDAO, "%d+"))

            if player3PPBetAmountValueDAO then
                if player3PPSideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player3213BetTextDAO = dealerFrameDAO.player3213BetLabelDAO:GetText()

        if player3213BetTextDAO and player3213BetTextDAO ~= "" then
            player3213BetAmountValueDAO = tonumber(string.match(player3213BetTextDAO, "%d+"))
            
            if player3213BetAmountValueDAO then
                if player3213SideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

    end
    dealerFrameDAO.player3NormalCoinsDAO:Hide()
    dealerFrameDAO.player3NormalWinCoinsDAO:Show()
end

-- Player 3 Split Hand 1 Win
function player3SplitH1WinDAO(messageDAO)
    player3SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1LabelDAO:GetText(), "%d+"))
    if player3SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(0, 1, 0)

        player3SplitHand1NormalWinAmountValueDAO = player3SplitHand1BetAmountValueDAO * 2
        dealerFrameDAO.player3SplitHand1LabelDAO:SetText(player3SplitHand1NormalWinAmountValueDAO .. " G")
        player3Hand1BetAmountTextDAO:SetText("H1: " .. player3SplitHand1NormalWinAmountValueDAO .. " G")

        player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")
    
        player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")
    
        player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3SplitHand1NormalWinAmountValueDAO)
        bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

        if player3BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

    end

    dealerFrameDAO.player3SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player3SplitHand1NormalWinCoinsDAO:Show()

end

-- Player 3 Split Hand 2 Win
function player3SplitH2WinDAO(messageDAO)
    player3SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2LabelDAO:GetText(), "%d+"))
    if player3SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(0, 1, 0)

        player3SplitHand2NormalWinAmountValueDAO = player3SplitHand2BetAmountValueDAO * 2
        dealerFrameDAO.player3SplitHand2LabelDAO:SetText(player3SplitHand2NormalWinAmountValueDAO .. " G")
        player3Hand2BetAmountTextDAO:SetText("H2: " .. player3SplitHand2NormalWinAmountValueDAO .. " G")

        player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")
    
        player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")
    
        player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3SplitHand2NormalWinAmountValueDAO)
        bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

        if player3BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player3PPBetTextDAO = dealerFrameDAO.player3PPBetLabelDAO:GetText()

        if player3PPBetTextDAO and player3PPBetTextDAO ~= "" then
            player3PPBetAmountValueDAO = tonumber(string.match(player3PPBetTextDAO, "%d+"))

            if player3PPBetAmountValueDAO then
                if player3PPSideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3PPBetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player3213BetTextDAO = dealerFrameDAO.player3213BetLabelDAO:GetText()

        if player3213BetTextDAO and player3213BetTextDAO ~= "" then
            player3213BetAmountValueDAO = tonumber(string.match(player3213BetTextDAO, "%d+"))
            
            if player3213BetAmountValueDAO then
                if player3213SideBetWinDAO == false then

                    player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3213BetAmountValueDAO)
                    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                    if player3BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

    end

    dealerFrameDAO.player3SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player3SplitHand2NormalWinCoinsDAO:Show()

end

-- Player 3 BJ Win
function player3BJWinDAO(messageDAO)
    player3MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3MainBetLabelDAO:GetText(), "%d+"))
    if player3MainBetAmountValueDAO then
        player3BJWinAmountValueDAO = player3MainBetAmountValueDAO * 2.5
        dealerFrameDAO.player3MainBetLabelDAO:SetText(player3BJWinAmountValueDAO .. " G")
        player3MainBetAmountTextDAO:SetText("Main Bet: " .. player3BJWinAmountValueDAO .. " G")
    end

    player3BJProfitvalueDAO = player3BJWinAmountValueDAO - player3MainBetAmountValueDAO

    player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3BJProfitvalueDAO)
    bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3BJProfitvalueDAO)
    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

    player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3BJWinAmountValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

    if player3BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player3PPBetTextDAO = dealerFrameDAO.player3PPBetLabelDAO:GetText()

    if player3PPBetTextDAO and player3PPBetTextDAO ~= "" then
        player3PPBetAmountValueDAO = tonumber(string.match(player3PPBetTextDAO, "%d+"))

        if player3PPBetAmountValueDAO then
            if player3PPSideBetWinDAO == false then

                player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3PPBetAmountValueDAO)
                bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3PPBetAmountValueDAO)
                bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                if player3BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    local player3213BetTextDAO = dealerFrameDAO.player3213BetLabelDAO:GetText()

    if player3213BetTextDAO and player3213BetTextDAO ~= "" then
        player3213BetAmountValueDAO = tonumber(string.match(player3213BetTextDAO, "%d+"))
        
        if player3213BetAmountValueDAO then
            if player3213SideBetWinDAO == false then

                player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3213BetAmountValueDAO)
                bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3213BetAmountValueDAO)
                bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                if player3BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

    dealerFrameDAO.player3NormalCoinsDAO:Hide()
    dealerFrameDAO.player3BJWinCoinsDAO:Show()

end

-- Player 3 Split Hand 1 BJ Win
function player3SplitH1BJDAO(messageDAO)
    player3SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1LabelDAO:GetText(), "%d+"))
    if player3SplitHand1BetAmountValueDAO then
        player3SplitHand1BJWinAmountValueDAO = player3SplitHand1BetAmountValueDAO * 2.5
        dealerFrameDAO.player3SplitHand1LabelDAO:SetText(player3SplitHand1BJWinAmountValueDAO .. " G")
        player3Hand1BetAmountTextDAO:SetText("H1: " .. player3SplitHand1BJWinAmountValueDAO .. " G")
    end

    player3SplitHand1BJProfitValueDAO = player3SplitHand1BJWinAmountValueDAO - player3SplitHand1BetAmountValueDAO

    player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3SplitHand1BJProfitValueDAO)
    bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3SplitHand1BJProfitValueDAO)
    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

    player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3SplitHand1BJWinAmountValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

    if player3BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player3PPBetTextDAO = dealerFrameDAO.player3PPBetLabelDAO:GetText()

    dealerFrameDAO.player3SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player3SplitHand1BJWinCoinsDAO:Show()

end

-- Player 3 Split Hand 2 BJ Win
function player3SplitH2BJDAO(messageDAO)
    player3SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2LabelDAO:GetText(), "%d+"))
    if player3SplitHand2BetAmountValueDAO then
        player3SplitHand2BJWinAmountValueDAO = player3SplitHand2BetAmountValueDAO * 2.5
        dealerFrameDAO.player3SplitHand2LabelDAO:SetText(player3SplitHand2BJWinAmountValueDAO .. " G")
        player3Hand2BetAmountTextDAO:SetText("H2: " .. player3SplitHand2BJWinAmountValueDAO .. " G")
    end

    player3SplitHand2BJProfitValueDAO = player3SplitHand2BJWinAmountValueDAO - player3SplitHand2BetAmountValueDAO

    player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3SplitHand2BJProfitValueDAO)
    bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3SplitHand2BJProfitValueDAO)
    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

    player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3SplitHand2BJWinAmountValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

    if player3BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player3PPBetTextDAO = dealerFrameDAO.player3PPBetLabelDAO:GetText()

    if player3PPBetTextDAO and player3PPBetTextDAO ~= "" then
        player3PPBetAmountValueDAO = tonumber(string.match(player3PPBetTextDAO, "%d+"))

        if player3PPBetAmountValueDAO then
            if player3PPSideBetWinDAO == false then

                player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3PPBetAmountValueDAO)
                bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3PPBetAmountValueDAO)
                bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                if player3BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    local player3213BetTextDAO = dealerFrameDAO.player3213BetLabelDAO:GetText()

    if player3213BetTextDAO and player3213BetTextDAO ~= "" then
        player3213BetAmountValueDAO = tonumber(string.match(player3213BetTextDAO, "%d+"))
        
        if player3213BetAmountValueDAO then
            if player3213SideBetWinDAO == false then

                player3BankingTotalLostDAO = player3BankingTotalLostDAO + tonumber(player3213BetAmountValueDAO)
                bankingFrameDAO.player3totalLostAmountDAO:SetText(player3BankingTotalLostDAO .. " G")

                player3BankingTotalProfitDAO = player3BankingTotalProfitDAO - tonumber(player3213BetAmountValueDAO)
                bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

                if player3BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    dealerFrameDAO.player3SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player3SplitHand2BJWinCoinsDAO:Show()

end

-- Player 3 Main Bet Complete Function
function player3HandleMainBetDAO(messageDAO)
    player3PlaceMainBetDAO()
    player3ActiveDAO = true
    local player3MainBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player3MainBetAmountValueDAO then
            player3PlaceMainBetTextDAO(player3MainBetAmountValueDAO)
            player3MainBetAmountTextDAO:SetText("Main Bet: " .. player3MainBetAmountValueDAO .. " G")
            player3TotalBetAmountDAO = player3TotalBetAmountDAO + tonumber(player3MainBetAmountValueDAO)
            player3TotalAmountTextDAO:SetText("Total: " .. player3TotalBetAmountDAO .. " G")
        else
    end

    player3BankingTotalWageredDAO = player3BankingTotalWageredDAO + tonumber(player3MainBetAmountValueDAO)
    bankingFrameDAO.player3totalWageredAmountDAO:SetText(player3BankingTotalWageredDAO .. " G")

    player3BankingBankrollDAO = player3BankingBankrollDAO - tonumber(player3MainBetAmountValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

end

-- Player 3 Double Bet Complete Function
function player3HandleDoubleBetDAO(messageDAO)
    player3PlaceDoubleBetDAO()
    local player3DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player3OriginalBetAmountValueDAO = tonumber(player3DoubleBetAmountValueDAO) / 2
    if player3DoubleBetAmountValueDAO then
        player3PlaceMainBetTextDAO(player3DoubleBetAmountValueDAO)
        player3MainBetAmountTextDAO:SetText("Main Bet: " .. player3DoubleBetAmountValueDAO .. " G")
        player3TotalBetAmountDAO = player3TotalBetAmountDAO + player3OriginalBetAmountValueDAO
        player3TotalAmountTextDAO:SetText("Total: " .. player3TotalBetAmountDAO .. " G")
    else
    end

    player3BankingTotalWageredDAO = player3BankingTotalWageredDAO + tonumber(player3OriginalBetAmountValueDAO)
    bankingFrameDAO.player3totalWageredAmountDAO:SetText(player3BankingTotalWageredDAO .. " G")

    player3BankingBankrollDAO = player3BankingBankrollDAO - tonumber(player3OriginalBetAmountValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

end

-- Player 3 Split Hand 1 Double Bet Complete Function
function player3SplitHand1DoubleBetDAO(messageDAO)
    
    dealerFrameDAO.player3SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player3SplitHand1DoubleCoinsDAO:Show()

    local player3SplitH1DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player3SplitH1OriginalBetAmountValueDAO = tonumber(player3SplitH1DoubleBetAmountValueDAO) / 2
    if player3SplitH1DoubleBetAmountValueDAO then
        dealerFrameDAO.player3SplitHand1LabelDAO:SetText(player3SplitH1DoubleBetAmountValueDAO .. " G")
        player3Hand1BetAmountTextDAO:SetText("H1: " .. player3SplitH1DoubleBetAmountValueDAO .. " G")
        player3TotalBetAmountDAO = player3TotalBetAmountDAO + player3SplitH1OriginalBetAmountValueDAO
        player3TotalAmountTextDAO:SetText("Total: " .. player3TotalBetAmountDAO .. " G")
    end

    player3BankingTotalWageredDAO = player3BankingTotalWageredDAO + tonumber(player3SplitH1OriginalBetAmountValueDAO)
    bankingFrameDAO.player3totalWageredAmountDAO:SetText(player3BankingTotalWageredDAO .. " G")

    player3BankingBankrollDAO = player3BankingBankrollDAO - tonumber(player3SplitH1OriginalBetAmountValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

end

-- Player 3 Split Hand 2 Double Bet Complete Function
function player3SplitHand2DoubleBetDAO(messageDAO)
    
    dealerFrameDAO.player3SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player3SplitHand2DoubleCoinsDAO:Show()

    local player3SplitH2DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player3SplitH2OriginalBetAmountValueDAO = tonumber(player3SplitH2DoubleBetAmountValueDAO) / 2
    if player3SplitH2DoubleBetAmountValueDAO then
        dealerFrameDAO.player3SplitHand2LabelDAO:SetText(player3SplitH2DoubleBetAmountValueDAO .. " G")
        player3Hand2BetAmountTextDAO:SetText("H2: " .. player3SplitH2DoubleBetAmountValueDAO .. " G")
        player3TotalBetAmountDAO = player3TotalBetAmountDAO + player3SplitH2OriginalBetAmountValueDAO
        player3TotalAmountTextDAO:SetText("Total: " .. player3TotalBetAmountDAO .. " G")
    end

    player3BankingTotalWageredDAO = player3BankingTotalWageredDAO + tonumber(player3SplitH2OriginalBetAmountValueDAO)
    bankingFrameDAO.player3totalWageredAmountDAO:SetText(player3BankingTotalWageredDAO .. " G")

    player3BankingBankrollDAO = player3BankingBankrollDAO - tonumber(player3SplitH2OriginalBetAmountValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

end

-- Player 3 Split Hand Bet Text
function player3SplitHand1BetTextDAO(AmountDAO)
    dealerFrameDAO.player3MainBetLabelDAO:Hide()
    dealerFrameDAO.player3MainBetLabelDAO:SetText("")
    dealerFrameDAO.player3SplitHand1LabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player3SplitHand1LabelDAO:Show()
    dealerFrameDAO.player3SplitHand2LabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player3SplitHand2LabelDAO:Show()
end

-- Player 3 Split Bet Image
function player3PlaceSplitBetDAO(messageDAO)
    dealerFrameDAO.player3NormalCoinsDAO:Hide()
    dealerFrameDAO.player3SplitHand2CoinsDAO:Show()
    dealerFrameDAO.player3SplitHand1CoinsDAO:Show()
end

-- Player 3 Place Initial Card ImagesDAO
function player3PlaceSplitCardsDAO(messageDAO)

    -- Players: 3
    if not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[3]:Hide()
        player3cardName1DAO = dealtCardsDAO[1]
        player3cardName2DAO = dealtCardsDAO[3]
        turnDAO = 8 -- Player 3: 2nd Card (Split H1)

    -- Players: 1, 3
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[2]:Hide()
        cardImagesDAO[5]:Hide()
        player3cardName1DAO = dealtCardsDAO[2]
        player3cardName2DAO = dealtCardsDAO[5]
        turnDAO = 30 -- Player 3: 2nd Card (Split H1)
    -- Players: 2, 3
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[2]:Hide()
        cardImagesDAO[5]:Hide()
        player3cardName1DAO = dealtCardsDAO[2]
        player3cardName2DAO = dealtCardsDAO[5]
        turnDAO = 30 -- Player 3: 2nd Card (Split H1)
    -- Players: 3, 4
    elseif not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[4]:Hide()
        player3cardName1DAO = dealtCardsDAO[1]
        player3cardName2DAO = dealtCardsDAO[4]
        turnDAO = 10 -- Player 3: 2nd Card (Split H1)
    -- Players: 3, 5
    elseif not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[4]:Hide()
        player3cardName1DAO = dealtCardsDAO[1]
        player3cardName2DAO = dealtCardsDAO[4]
        turnDAO = 10 -- Player 3: 2nd Card (Split H1)

    -- Players: 1, 2, 3
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[7]:Hide()
        player3cardName1DAO = dealtCardsDAO[3]
        player3cardName2DAO = dealtCardsDAO[7]
        turnDAO = 52 -- Player 3: 2nd Card (Split H1)
    -- Players: 1, 3, 4
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[6]:Hide()
        player3cardName1DAO = dealtCardsDAO[2]
        player3cardName2DAO = dealtCardsDAO[6]
        turnDAO = 32 -- Player 3: 2nd Card (Split H1)
    -- Players: 1, 3, 5
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[6]:Hide()
        player3cardName1DAO = dealtCardsDAO[2]
        player3cardName2DAO = dealtCardsDAO[6]
        turnDAO = 32 -- Player 3: 2nd Card (Split H1)
    -- Players: 2, 3, 4
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[6]:Hide()
        player3cardName1DAO = dealtCardsDAO[2]
        player3cardName2DAO = dealtCardsDAO[6]
        turnDAO = 32 -- Player 3: 2nd Card (Split H1)
    -- Players: 2, 3, 5
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[6]:Hide()
        player3cardName1DAO = dealtCardsDAO[2]
        player3cardName2DAO = dealtCardsDAO[6]
        turnDAO = 32 -- Player 3: 2nd Card (Split H1)
    -- Players: 3, 4, 5
    elseif not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[1]:Hide()
        cardImagesDAO[5]:Hide()
        player3cardName1DAO = dealtCardsDAO[1]
        player3cardName2DAO = dealtCardsDAO[5]
        turnDAO = 12 -- Player 3: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[8]:Hide()
        player3cardName1DAO = dealtCardsDAO[3]
        player3cardName2DAO = dealtCardsDAO[8]
        turnDAO = 54 -- Player 3: 2nd Card (Split H1)
    -- Players: 1, 2, 3, 5
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[8]:Hide()
        player3cardName1DAO = dealtCardsDAO[3]
        player3cardName2DAO = dealtCardsDAO[8]
        turnDAO = 54 -- Player 3: 2nd Card (Split H1)
    -- Players: 1, 3, 4, 5
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[7]:Hide()
        player3cardName1DAO = dealtCardsDAO[2]
        player3cardName2DAO = dealtCardsDAO[7]
        turnDAO = 34 -- Player 3: 2nd Card (Split H1)
    -- Players: 2, 3, 4, 5
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[7]:Hide()
        player3cardName1DAO = dealtCardsDAO[2]
        player3cardName2DAO = dealtCardsDAO[7]
        turnDAO = 34 -- Player 3: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4, 5
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[9]:Hide()
        player3cardName1DAO = dealtCardsDAO[3]
        player3cardName2DAO = dealtCardsDAO[9]
        turnDAO = 56 -- Player 3: 2nd Card (Split H1)

    end

    player3cardImageFile1DAO = nil
    player3cardImageFile2DAO = nil

    for filenameDAO, cardDescriptionDAO in pairs(cardNamesDAO) do
        if cardDescriptionDAO == player3cardName1DAO then
            player3cardImageFile1DAO = filenameDAO
            break
        end
    end

    for filenameDAO, cardDescriptionDAO in pairs(cardNamesDAO) do
        if cardDescriptionDAO == player3cardName2DAO then
            player3cardImageFile2DAO = filenameDAO
            break
        end
    end

    player3NewCardImage1DAO = CreateFrame("Frame", nil, dealerFrameDAO)
    player3NewCardImage1DAO:SetSize(24, 48)
    player3NewCardImage1DAO:SetPoint("CENTER", dealerFrameDAO, -4, 8)
    player3NewCardImage1DAO.texture = player3NewCardImage1DAO:CreateTexture()
    player3NewCardImage1DAO.texture:SetAllPoints()
    player3NewCardImage1DAO.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. player3cardImageFile1DAO)
    player3NewCardImage1DAO:Show()

    player3NewCardImage2DAO = CreateFrame("Frame", nil, dealerFrameDAO)
    player3NewCardImage2DAO:SetSize(24, 48)
    player3NewCardImage2DAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)
    player3NewCardImage2DAO.texture = player3NewCardImage2DAO:CreateTexture()
    player3NewCardImage2DAO.texture:SetAllPoints()
    player3NewCardImage2DAO.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. player3cardImageFile2DAO)
    player3NewCardImage2DAO:Show()

end

-- Player 3 Split Function
function player3HandleSplitDAO(messageDAO)
    player3PlaceSplitBetDAO()
    local player3MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player3MainBetLabelDAO:GetText(), "%d+"))
    if player3MainBetAmountValueDAO then
        player3SplitHand1BetTextDAO(player3MainBetAmountValueDAO)
        player3MainBetAmountTextDAO:Hide()
        player3Hand1BetAmountTextDAO:Show()
        player3Hand2BetAmountTextDAO:Show()
        player3Hand1BetAmountTextDAO:SetText("H1: " .. player3MainBetAmountValueDAO .. " G")
        player3Hand2BetAmountTextDAO:SetText("H2: " .. player3MainBetAmountValueDAO .. " G")
        player3TotalBetAmountDAO = player3TotalBetAmountDAO + player3MainBetAmountValueDAO
        player3TotalAmountTextDAO:SetText("Total: " .. player3TotalBetAmountDAO .. " G")
    else
    end 

    dealerFrameDAO.player3CardTotalTextDAO:SetText("")
    dealerFrameDAO.player3CardTotalTextDAO:Hide()

    if player3RunningTotalDAO == 2 then
        dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("1 or 11")
        dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("1 or 11")
        dealerFrameDAO.player3SplitHand1CardTotalTextDAO:Show()
        dealerFrameDAO.player3SplitHand2CardTotalTextDAO:Show()
    else
        dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText(player3S1RunningTotalDAO)
        dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText(player3S2RunningTotalDAO)
        dealerFrameDAO.player3SplitHand1CardTotalTextDAO:Show()
        dealerFrameDAO.player3SplitHand2CardTotalTextDAO:Show()
    end

    player3BankingTotalWageredDAO = player3BankingTotalWageredDAO + tonumber(player3MainBetAmountValueDAO)
    bankingFrameDAO.player3totalWageredAmountDAO:SetText(player3BankingTotalWageredDAO .. " G")

    player3BankingBankrollDAO = player3BankingBankrollDAO - tonumber(player3MainBetAmountValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")
    
    player3PlaceSplitCardsDAO()
    
end

-- Player 3 PP Bet Image
function player3PlacePPBetDAO(messageDAO)
    dealerFrameDAO.player3PPCoinsDAO:Show()
end

-- Player 3 PP Bet Text
function player3PlacePPBetTextDAO(AmountDAO)
    dealerFrameDAO.player3PPBetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player3PPBetLabelDAO:Show()
end

-- Player 3 PP Win
function player3PPWinDAO(messageDAO)
    dealerFrameDAO.player3PPCoinsDAO:Hide()
    dealerFrameDAO.player3PPWinCoinsDAO:Show()
    dealerFrameDAO.player3PPBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 57, 71)
end

-- Player 3 PP Bet Complete Function
function player3HandlePPBetDAO(messageDAO)
    player3PlacePPBetDAO()
    local player3PPBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player3PPBetAmountValueDAO then
            player3PlacePPBetTextDAO(player3PPBetAmountValueDAO)
            player3PPAmountTextDAO:SetText("PP Side Bet: " .. player3PPBetAmountValueDAO .. " G")
            player3TotalBetAmountDAO = player3TotalBetAmountDAO + tonumber(player3PPBetAmountValueDAO)
            player3TotalAmountTextDAO:SetText("Total: " .. player3TotalBetAmountDAO .. " G")
        else
    end

    player3BankingTotalWageredDAO = player3BankingTotalWageredDAO + tonumber(player3PPBetAmountValueDAO)
    bankingFrameDAO.player3totalWageredAmountDAO:SetText(player3BankingTotalWageredDAO .. " G")

    player3BankingBankrollDAO = player3BankingBankrollDAO - tonumber(player3PPBetAmountValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

end

-- Player 3 21+3 Bet Image
function player3Place213BetDAO(messageDAO)
    dealerFrameDAO.player3213CoinsDAO:Show()
end

-- Player 3 21+3 Bet Text
function player3Place213BetTextDAO(AmountDAO)
    dealerFrameDAO.player3213BetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player3213BetLabelDAO:Show()
end

-- Player 3 21+3 Win
function player3213WinDAO(messageDAO)
    dealerFrameDAO.player3213CoinsDAO:Hide()
    dealerFrameDAO.player3213WinCoinsDAO:Show()
    dealerFrameDAO.player3213BetLabelDAO:SetPoint("CENTER", dealerFrameDAO, -31, 71)
end

-- Player 3 21+3 Bet Complete Function
function player3Handle213BetDAO(messageDAO)
    player3Place213BetDAO()
    local player3213BetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player3213BetAmountValueDAO then
            player3Place213BetTextDAO(player3213BetAmountValueDAO)
            player3213AmountTextDAO:SetText("21+3 Side Bet: " .. player3213BetAmountValueDAO .. " G")
            player3TotalBetAmountDAO = player3TotalBetAmountDAO + tonumber(player3213BetAmountValueDAO)
            player3TotalAmountTextDAO:SetText("Total: " .. player3TotalBetAmountDAO .. " G")
        else
    end

    player3BankingTotalWageredDAO = player3BankingTotalWageredDAO + tonumber(player3213BetAmountValueDAO)
    bankingFrameDAO.player3totalWageredAmountDAO:SetText(player3BankingTotalWageredDAO .. " G")

    player3BankingBankrollDAO = player3BankingBankrollDAO - tonumber(player3213BetAmountValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

end

function player3MixedPairWinDAO(messageDAO)
    player3PPSideBetWinDAO = true
    player3PPAmountTextValueDAO = tonumber(string.match(player3PPAmountTextDAO:GetText(), "%d+"))
    if player3PPAmountTextValueDAO then
        player3PPWinValueDAO = player3PPAmountTextValueDAO * mixedPairPayoutReturnDAO
        player3PPAmountTextDAO:SetText("PP Side Bet: " .. player3PPWinValueDAO .. " G")
        player3PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player3PPBetLabelDAO:SetText(player3PPWinValueDAO .. " G")
    end

    player3PPProfitValueDAO = player3PPWinValueDAO - player3PPAmountTextValueDAO

    player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3PPProfitValueDAO)
    bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3PPProfitValueDAO)
    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

    if player3BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3PPWinValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

    player3PPWinDAO()
end

function player3ColouredPairWinDAO(messageDAO)
    player3PPSideBetWinDAO = true
    player3PPAmountTextValueDAO = tonumber(string.match(player3PPAmountTextDAO:GetText(), "%d+"))
    if player3PPAmountTextValueDAO then
        player3PPWinValueDAO = player3PPAmountTextValueDAO * colouredPairPayoutReturnDAO
        player3PPAmountTextDAO:SetText("PP Side Bet: " .. player3PPWinValueDAO .. " G")
        player3PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player3PPBetLabelDAO:SetText(player3PPWinValueDAO .. " G")
    end

    player3PPProfitValueDAO = player3PPWinValueDAO - player3PPAmountTextValueDAO

    player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3PPProfitValueDAO)
    bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3PPProfitValueDAO)
    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

    if player3BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3PPWinValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

    player3PPWinDAO()
end

function player3PerfectPairWinDAO(messageDAO)
    player3PPSideBetWinDAO = true
    player3PPAmountTextValueDAO = tonumber(string.match(player3PPAmountTextDAO:GetText(), "%d+"))
    if player3PPAmountTextValueDAO then
        player3PPWinValueDAO = player3PPAmountTextValueDAO * perfectPairPayoutReturnDAO
        player3PPAmountTextDAO:SetText("PP Side Bet: " .. player3PPWinValueDAO .. " G")
        player3PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player3PPBetLabelDAO:SetText(player3PPWinValueDAO .. " G")
    end

    player3PPProfitValueDAO = player3PPWinValueDAO - player3PPAmountTextValueDAO

    player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3PPProfitValueDAO)
    bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3PPProfitValueDAO)
    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

    if player3BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3PPWinValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

    player3PPWinDAO()
end

function player3SuitedThreeOfAKindWinDAO(messageDAO)
    player3213SideBetWinDAO = true
    player3213AmountTextValueDAO = tonumber(string.match(player3213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player3213AmountTextValueDAO then
        player3213WinValueDAO = player3213AmountTextValueDAO * suitedThreeOfAKindPayoutReturnDAO
        player3213AmountTextDAO:SetText("21+3 Side Bet: " .. player3213WinValueDAO .. " G")
        player3213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player3213BetLabelDAO:SetText(player3213WinValueDAO .. " G")
    end

    player3213ProfitValueDAO = player3213WinValueDAO - player3213AmountTextValueDAO

    player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3213ProfitValueDAO)
    bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3213ProfitValueDAO)
    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

    if player3BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3213WinValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

    player3213WinDAO()
end

function player3StraightFlushWinDAO(messageDAO)
    player3213SideBetWinDAO = true
    player3213AmountTextValueDAO = tonumber(string.match(player3213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player3213AmountTextValueDAO then
        player3213WinValueDAO = player3213AmountTextValueDAO * straightFlushPayoutReturnDAO
        player3213AmountTextDAO:SetText("21+3 Side Bet: " .. player3213WinValueDAO .. " G")
        player3213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player3213BetLabelDAO:SetText(player3213WinValueDAO .. " G")
    end

    player3213ProfitValueDAO = player3213WinValueDAO - player3213AmountTextValueDAO

    player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3213ProfitValueDAO)
    bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3213ProfitValueDAO)
    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

    if player3BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3213WinValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

    player3213WinDAO()
end

function player3ThreeOfAKindWinDAO(messageDAO)
    player3213SideBetWinDAO = true
    player3213AmountTextValueDAO = tonumber(string.match(player3213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player3213AmountTextValueDAO then
        player3213WinValueDAO = player3213AmountTextValueDAO * threeOfAKindPayoutReturnDAO
        player3213AmountTextDAO:SetText("21+3 Side Bet: " .. player3213WinValueDAO .. " G")
        player3213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player3213BetLabelDAO:SetText(player3213WinValueDAO .. " G")
    end

    player3213ProfitValueDAO = player3213WinValueDAO - player3213AmountTextValueDAO

    player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3213ProfitValueDAO)
    bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3213ProfitValueDAO)
    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

    if player3BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3213WinValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

    player3213WinDAO()
end

function player3StraightWinDAO(messageDAO)
    player3213SideBetWinDAO = true
    player3213AmountTextValueDAO = tonumber(string.match(player3213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player3213AmountTextValueDAO then
        player3213WinValueDAO = player3213AmountTextValueDAO * straightPayoutReturnDAO
        player3213AmountTextDAO:SetText("21+3 Side Bet: " .. player3213WinValueDAO .. " G")
        player3213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player3213BetLabelDAO:SetText(player3213WinValueDAO .. " G")
    end

    player3213ProfitValueDAO = player3213WinValueDAO - player3213AmountTextValueDAO

    player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3213ProfitValueDAO)
    bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3213ProfitValueDAO)
    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

    if player3BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3213WinValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")

    player3213WinDAO()
end

function player3FlushWinDAO(messageDAO)
    player3213SideBetWinDAO = true
    player3213AmountTextValueDAO = tonumber(string.match(player3213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player3213AmountTextValueDAO then
        player3213WinValueDAO = player3213AmountTextValueDAO * flushPayoutReturnDAO
        player3213AmountTextDAO:SetText("21+3 Side Bet: " .. player3213WinValueDAO .. " G")
        player3213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player3213BetLabelDAO:SetText(player3213WinValueDAO .. " G")
    end

    player3213ProfitValueDAO = player3213WinValueDAO - player3213AmountTextValueDAO

    player3BankingTotalWonDAO = player3BankingTotalWonDAO + tonumber(player3213ProfitValueDAO)
    bankingFrameDAO.player3totalWonAmountDAO:SetText(player3BankingTotalWonDAO .. " G")

    player3BankingTotalProfitDAO = player3BankingTotalProfitDAO + tonumber(player3213ProfitValueDAO)
    bankingFrameDAO.player3totalProfitAmountDAO:SetText(player3BankingTotalProfitDAO .. " G")

    if player3BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player3totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player3BankingBankrollDAO = player3BankingBankrollDAO + tonumber(player3213WinValueDAO)
    bankingFrameDAO.player3BankrollAmountDAO:SetText(player3BankingBankrollDAO .. " G")
    
    player3213WinDAO()
end
































-- >>> PLAYER 4 <<<
-- >>> PLAYER 4 <<<
-- >>> PLAYER 4 <<<

-- Bet Amounts
-- "Player 4" titleDAO
player4TitleTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player4TitleTextDAO:SetPoint("CENTER", dealerFrameDAO, 206, 182)
player4TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player4TitleTextDAO:SetJustifyH("CENTER")
player4TitleTextDAO:SetText("Player 4")
-- Player 4 character nameDAO
player4NameTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player4NameTextDAO:SetPoint("CENTER", dealerFrameDAO, 206, 164)
player4NameTextDAO:SetText("Seat Empty")
player4NameTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
-- Player 4 "Main Bet" amount text
player4MainBetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player4MainBetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 206, 145)
player4MainBetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player4MainBetAmountTextDAO:SetJustifyH("CENTER")
player4MainBetAmountTextDAO:SetText("Main Bet: N/A")
player4MainBetAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 4 "Hand 1 Bet" amount text
player4Hand1BetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player4Hand1BetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 170, 145)
player4Hand1BetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player4Hand1BetAmountTextDAO:SetJustifyH("CENTER")
player4Hand1BetAmountTextDAO:SetText("H1: N/A")
player4Hand1BetAmountTextDAO:SetTextColor(1, 1, 1)
player4Hand1BetAmountTextDAO:Hide()
-- Player 4 "Hand 2 Bet" amount text
player4Hand2BetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player4Hand2BetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 242, 145)
player4Hand2BetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player4Hand2BetAmountTextDAO:SetJustifyH("CENTER")
player4Hand2BetAmountTextDAO:SetText("H2: N/A")
player4Hand2BetAmountTextDAO:SetTextColor(1, 1, 1)
player4Hand2BetAmountTextDAO:Hide()
-- Player 4 "Insurance Bet" amount text
player4InsuranceAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player4InsuranceAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 206, 134)
player4InsuranceAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player4InsuranceAmountTextDAO:SetJustifyH("CENTER")
player4InsuranceAmountTextDAO:SetText("Insurance: N/A")
player4InsuranceAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 4 "21+3 Side Bet" amount text
player4213AmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player4213AmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 206, 123)
player4213AmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player4213AmountTextDAO:SetJustifyH("CENTER")
player4213AmountTextDAO:SetText("21+3 Side Bet: N/A")
player4213AmountTextDAO:SetTextColor(1, 1, 1)
-- Player 4 "PP Side Bet" amount text
player4PPAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player4PPAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 206, 112)
player4PPAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player4PPAmountTextDAO:SetJustifyH("CENTER")
player4PPAmountTextDAO:SetText("PP Side Bet: N/A")
player4PPAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 4 "Total Bet" amount text
player4TotalAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player4TotalAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 206, 101)
player4TotalAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player4TotalAmountTextDAO:SetJustifyH("CENTER")
player4TotalAmountTextDAO:SetText("Total: N/A")
player4TotalAmountTextDAO:SetTextColor(1, 1, 0.5)
-- Card Total for Player 4
dealerFrameDAO.player4CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player4CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", 168, 82)
dealerFrameDAO.player4CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player4CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player4CardTotalTextDAO:SetText("")
-- Card Total (Split Hand 1) for Player 4
dealerFrameDAO.player4SplitHand1CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", 145, 92)
dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("")
-- Card Total (Split Hand 2) for Player 4
dealerFrameDAO.player4SplitHand2CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", 195, 66)
dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("")

-- ImagesDAO for Player 4
-- Main Bet
dealerFrameDAO.player4NormalCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4NormalCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4NormalCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 136, 48)
dealerFrameDAO.player4NormalCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player4NormalCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4NormalCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4NormalCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4NormalCoinsDAO:Hide()
-- Split Bet Hand 1
dealerFrameDAO.player4SplitHand1CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4SplitHand1CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4SplitHand1CoinsDAO:SetPoint("CENTER", dealerFrameDAO, 116, 48)
dealerFrameDAO.player4SplitHand1CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player4SplitHand1CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4SplitHand1CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4SplitHand1CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4SplitHand1CoinsDAO:Hide()
-- Split Double Bet Hand 1
dealerFrameDAO.player4SplitHand1DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4SplitHand1DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4SplitHand1DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 116, 48)
dealerFrameDAO.player4SplitHand1DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player4SplitHand1DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4SplitHand1DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4SplitHand1DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4SplitHand1DoubleCoinsDAO:Hide()
-- Split Bet Hand 2
dealerFrameDAO.player4SplitHand2CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4SplitHand2CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4SplitHand2CoinsDAO:SetPoint("CENTER", dealerFrameDAO, 143, 32)
dealerFrameDAO.player4SplitHand2CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player4SplitHand2CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4SplitHand2CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4SplitHand2CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4SplitHand2CoinsDAO:Hide()
-- Split Double Bet Hand 2
dealerFrameDAO.player4SplitHand2DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4SplitHand2DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4SplitHand2DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 143, 32)
dealerFrameDAO.player4SplitHand2DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player4SplitHand2DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4SplitHand2DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4SplitHand2DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4SplitHand2DoubleCoinsDAO:Hide()
-- Double Bet
dealerFrameDAO.player4DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 136, 48)
dealerFrameDAO.player4DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player4DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4DoubleCoinsDAO:Hide()
-- PP Bet
dealerFrameDAO.player4PPCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4PPCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4PPCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 171, -5)
dealerFrameDAO.player4PPCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsHalfBet.tga")
dealerFrameDAO.player4PPCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4PPCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4PPCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4PPCoinsDAO:Hide()
-- 21+3 Bet
dealerFrameDAO.player4213CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4213CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4213CoinsDAO:SetPoint("CENTER", dealerFrameDAO, 89, 32)
dealerFrameDAO.player4213CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsHalfBet.tga")
dealerFrameDAO.player4213CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4213CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4213CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4213CoinsDAO:Hide()
-- Win
dealerFrameDAO.player4NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 136, 48)
dealerFrameDAO.player4NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player4NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4NormalWinCoinsDAO:Hide()
-- Split Win Hand 1
dealerFrameDAO.player4SplitHand1NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4SplitHand1NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4SplitHand1NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 116, 48)
dealerFrameDAO.player4SplitHand1NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player4SplitHand1NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4SplitHand1NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4SplitHand1NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4SplitHand1NormalWinCoinsDAO:Hide()
-- Split Win Hand 2
dealerFrameDAO.player4SplitHand2NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4SplitHand2NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4SplitHand2NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 143, 32)
dealerFrameDAO.player4SplitHand2NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player4SplitHand2NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4SplitHand2NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4SplitHand2NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4SplitHand2NormalWinCoinsDAO:Hide()
-- Blackjack Win
dealerFrameDAO.player4BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 136, 48)
dealerFrameDAO.player4BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player4BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4BJWinCoinsDAO:Hide()
-- Split BJ Win Hand 1
dealerFrameDAO.player4SplitHand1BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4SplitHand1BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4SplitHand1BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 116, 48)
dealerFrameDAO.player4SplitHand1BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player4SplitHand1BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4SplitHand1BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4SplitHand1BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4SplitHand1BJWinCoinsDAO:Hide()
-- Split BJ Win Hand 2
dealerFrameDAO.player4SplitHand2BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4SplitHand2BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4SplitHand2BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 143, 32)
dealerFrameDAO.player4SplitHand2BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player4SplitHand2BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4SplitHand2BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4SplitHand2BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4SplitHand2BJWinCoinsDAO:Hide()
-- PP Win
dealerFrameDAO.player4PPWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4PPWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4PPWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 163, -1)
dealerFrameDAO.player4PPWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player4PPWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4PPWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4PPWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4PPWinCoinsDAO:Hide()
-- 21+3 Win
dealerFrameDAO.player4213WinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player4213WinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player4213WinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 79, 37)
dealerFrameDAO.player4213WinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player4213WinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player4213WinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player4213WinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player4213WinCoinsDAO:Hide()

-- Labels for Player 4
-- Main Bet AmountDAO
dealerFrameDAO.player4MainBetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player4MainBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 155, 75)
dealerFrameDAO.player4MainBetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player4MainBetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Split Hand 1 Bet AmountDAO
dealerFrameDAO.player4SplitHand1LabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player4SplitHand1LabelDAO:SetPoint("CENTER", dealerFrameDAO, 132, 75)
dealerFrameDAO.player4SplitHand1LabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player4SplitHand1LabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Split Hand 2 Bet AmountDAO
dealerFrameDAO.player4SplitHand2LabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player4SplitHand2LabelDAO:SetPoint("CENTER", dealerFrameDAO, 162, 58)
dealerFrameDAO.player4SplitHand2LabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player4SplitHand2LabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Perfect Pairs AmountDAO
dealerFrameDAO.player4PPBetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player4PPBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 181, 13)
dealerFrameDAO.player4PPBetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player4PPBetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- 21+3 AmountDAO
dealerFrameDAO.player4213BetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player4213BetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 97, 50)
dealerFrameDAO.player4213BetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player4213BetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Insurance YES for Player 4
player4InsuranceYesIconDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
player4InsuranceYesIconDAO:SetSize(14, 14)
player4InsuranceYesIconDAO:SetPoint("CENTER", dealerFrameDAO, 169, 183)
player4InsuranceYesIconDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\insuranceYes.tga")
player4InsuranceYesIconDAO:SetDrawLayer("OVERLAY")
player4InsuranceYesIconDAO:Hide()
-- Insurance NO for Player 4
player4InsuranceNoIconDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
player4InsuranceNoIconDAO:SetSize(14, 14)
player4InsuranceNoIconDAO:SetPoint("CENTER", dealerFrameDAO, 169, 183)
player4InsuranceNoIconDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\insuranceNo.tga")
player4InsuranceNoIconDAO:SetDrawLayer("OVERLAY")
player4InsuranceNoIconDAO:Hide()

function player4HandleInsuranceYesDAO(messageDAO)
    player4InsuranceYesIconDAO:Show()
    player4InsuranceBetValueDAO = string.match(messageDAO, "(%d+)G")
    if player4InsuranceBetValueDAO then
        player4InsuranceAmountTextDAO:SetText("Insurance: " .. player4InsuranceBetValueDAO .. " G")
        player4TotalBetAmountDAO = player4TotalBetAmountDAO + player4InsuranceBetValueDAO
        player4TotalAmountTextDAO:SetText("Total: " .. player4TotalBetAmountDAO .. " G")
    end

    player4BankingTotalWageredDAO = player4BankingTotalWageredDAO + tonumber(player4InsuranceBetValueDAO)
    bankingFrameDAO.player4totalWageredAmountDAO:SetText(player4BankingTotalWageredDAO .. " G")

    player4BankingBankrollDAO = player4BankingBankrollDAO - tonumber(player4InsuranceBetValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

end

function player4InsuranceWinDAO(messageDAO)
    player4InsuranceBetAmountValueDAO = tonumber(string.match(player4InsuranceAmountTextDAO:GetText(), "%d+"))
    if player4InsuranceBetAmountValueDAO then
        player4InsuranceWinAmountValueDAO = player4InsuranceBetAmountValueDAO * 3

        player4InsuranceProfitValueDAO = player4InsuranceWinAmountValueDAO - player4InsuranceBetAmountValueDAO

        player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4InsuranceProfitValueDAO)
        bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

        player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4InsuranceProfitValueDAO)
        bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

        if player4BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end
        
        player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4InsuranceWinAmountValueDAO)
        bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

        player4InsuranceAmountTextDAO:SetText("Insurance: " .. player4InsuranceWinAmountValueDAO .. " G")
        player4InsuranceAmountTextDAO:SetTextColor(0, 1, 0)

    end

end

function player4InsuranceLossDAO(messageDAO)
    if player4InsuranceAmountTextDAO:GetText() == "Insurance: N/A" then
        print("")
    else
        player4InsuranceBetAmountValueDAO = tonumber(string.match(player4InsuranceAmountTextDAO:GetText(), "%d+"))
        if player4InsuranceBetAmountValueDAO then

            player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4InsuranceBetAmountValueDAO)
            bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

            player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4InsuranceBetAmountValueDAO)
            bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")
        end
    end
end

function player4HandleInsuranceNoDAO(messageDAO)
    player4InsuranceNoIconDAO:Show()
    player4InsuranceAmountTextDAO:SetText("Insurance: 0 G")
end

-- Player 4 Main Bet Image
function player4PlaceMainBetDAO(messageDAO)
    dealerFrameDAO.player4NormalCoinsDAO:Show()
end

-- Player 4 Main Bet Text
function player4PlaceMainBetTextDAO(AmountDAO)
    dealerFrameDAO.player4MainBetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player4MainBetLabelDAO:Show()
end

-- Player 4 Double Bet Image
function player4PlaceDoubleBetDAO(messageDAO)
    dealerFrameDAO.player4NormalCoinsDAO:Hide()
    dealerFrameDAO.player4DoubleCoinsDAO:Show()
end

-- Player 4 Push
function player4PushDAO(messageDAO)
    player4MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4MainBetLabelDAO:GetText(), "%d+"))
    if player4MainBetAmountValueDAO then

        dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4MainBetAmountValueDAO)
        bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

        local player4PPBetTextDAO = dealerFrameDAO.player4PPBetLabelDAO:GetText()

        if player4PPBetTextDAO and player4PPBetTextDAO ~= "" then
            player4PPBetAmountValueDAO = tonumber(string.match(player4PPBetTextDAO, "%d+"))
            
            if player4PPBetAmountValueDAO then
                if player4PPSideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player4213BetTextDAO = dealerFrameDAO.player4213BetLabelDAO:GetText()

        if player4213BetTextDAO and player4213BetTextDAO ~= "" then
            player4213BetAmountValueDAO = tonumber(string.match(player4213BetTextDAO, "%d+"))

            if player4213BetAmountValueDAO then
                if player4213SideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 4 Split Hand 1 Push
function player4SplitH1PushDAO()
    player4SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1LabelDAO:GetText(), "%d+"))
    if player4SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

    end
end

-- Player 4 Split Hand 2 Push
function player4SplitH2PushDAO()
    player4SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2LabelDAO:GetText(), "%d+"))
    if player4SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

        local player4PPBetTextDAO = dealerFrameDAO.player4PPBetLabelDAO:GetText()

        if player4PPBetTextDAO and player4PPBetTextDAO ~= "" then
            player4PPBetAmountValueDAO = tonumber(string.match(player4PPBetTextDAO, "%d+"))
            
            if player4PPBetAmountValueDAO then
                if player4PPSideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player4213BetTextDAO = dealerFrameDAO.player4213BetLabelDAO:GetText()

        if player4213BetTextDAO and player4213BetTextDAO ~= "" then
            player4213BetAmountValueDAO = tonumber(string.match(player4213BetTextDAO, "%d+"))

            if player4213BetAmountValueDAO then
                if player4213SideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 4 Loss
function player4LossDAO(messageDAO)
    player4MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4MainBetLabelDAO:GetText(), "%d+"))
    if player4MainBetAmountValueDAO then

        dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)

        player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4MainBetAmountValueDAO)
        bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

        player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4MainBetAmountValueDAO)
        bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

        if player4BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player4PPBetTextDAO = dealerFrameDAO.player4PPBetLabelDAO:GetText()

        if player4PPBetTextDAO and player4PPBetTextDAO ~= "" then
            player4PPBetAmountValueDAO = tonumber(string.match(player4PPBetTextDAO, "%d+"))
            
            if player4PPBetAmountValueDAO then
                if player4PPSideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player4213BetTextDAO = dealerFrameDAO.player4213BetLabelDAO:GetText()

        if player4213BetTextDAO and player4213BetTextDAO ~= "" then
            player4213BetAmountValueDAO = tonumber(string.match(player4213BetTextDAO, "%d+"))

            if player4213BetAmountValueDAO then
                if player4213SideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 4 Split Hand 1 Loss
function player4SplitH1LossDAO()
    player4SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1LabelDAO:GetText(), "%d+"))
    if player4SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)

        player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

        player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

        if player4BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

    end

end

-- Player 4 Split Hand 2 Loss
function player4SplitH2LossDAO()
    player4SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2LabelDAO:GetText(), "%d+"))
    if player4SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)

        player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

        player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

        if player4BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player4PPBetTextDAO = dealerFrameDAO.player4PPBetLabelDAO:GetText()

        if player4PPBetTextDAO and player4PPBetTextDAO ~= "" then
            player4PPBetAmountValueDAO = tonumber(string.match(player4PPBetTextDAO, "%d+"))
            
            if player4PPBetAmountValueDAO then
                if player4PPSideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player4213BetTextDAO = dealerFrameDAO.player4213BetLabelDAO:GetText()

        if player4213BetTextDAO and player4213BetTextDAO ~= "" then
            player4213BetAmountValueDAO = tonumber(string.match(player4213BetTextDAO, "%d+"))

            if player4213BetAmountValueDAO then
                if player4213SideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 4 Win
function player4WinDAO(messageDAO)
    player4MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4MainBetLabelDAO:GetText(), "%d+"))
    if player4MainBetAmountValueDAO then

        dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(0, 1, 0)

        player4NormalWinAmountValueDAO = player4MainBetAmountValueDAO * 2
        dealerFrameDAO.player4MainBetLabelDAO:SetText(player4NormalWinAmountValueDAO .. " G")
        player4MainBetAmountTextDAO:SetText("Main Bet: " .. player4NormalWinAmountValueDAO .. " G")

        player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4MainBetAmountValueDAO)
        bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

        player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4MainBetAmountValueDAO)
        bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

        player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4NormalWinAmountValueDAO)
        bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

        if player4BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player4PPBetTextDAO = dealerFrameDAO.player4PPBetLabelDAO:GetText()

        if player4PPBetTextDAO and player4PPBetTextDAO ~= "" then
            player4PPBetAmountValueDAO = tonumber(string.match(player4PPBetTextDAO, "%d+"))

            if player4PPBetAmountValueDAO then
                if player4PPSideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player4213BetTextDAO = dealerFrameDAO.player4213BetLabelDAO:GetText()

        if player4213BetTextDAO and player4213BetTextDAO ~= "" then
            player4213BetAmountValueDAO = tonumber(string.match(player4213BetTextDAO, "%d+"))
            
            if player4213BetAmountValueDAO then
                if player4213SideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

    end
    dealerFrameDAO.player4NormalCoinsDAO:Hide()
    dealerFrameDAO.player4NormalWinCoinsDAO:Show()
end

-- Player 4 Split Hand 1 Win
function player4SplitH1WinDAO(messageDAO)
    player4SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1LabelDAO:GetText(), "%d+"))
    if player4SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(0, 1, 0)

        player4SplitHand1NormalWinAmountValueDAO = player4SplitHand1BetAmountValueDAO * 2
        dealerFrameDAO.player4SplitHand1LabelDAO:SetText(player4SplitHand1NormalWinAmountValueDAO .. " G")
        player4Hand1BetAmountTextDAO:SetText("H1: " .. player4SplitHand1NormalWinAmountValueDAO .. " G")

        player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")
    
        player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")
    
        player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4SplitHand1NormalWinAmountValueDAO)
        bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

        if player4BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

    end

    dealerFrameDAO.player4SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player4SplitHand1NormalWinCoinsDAO:Show()

end

-- Player 4 Split Hand 2 Win
function player4SplitH2WinDAO(messageDAO)
    player4SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2LabelDAO:GetText(), "%d+"))
    if player4SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(0, 1, 0)

        player4SplitHand2NormalWinAmountValueDAO = player4SplitHand2BetAmountValueDAO * 2
        dealerFrameDAO.player4SplitHand2LabelDAO:SetText(player4SplitHand2NormalWinAmountValueDAO .. " G")
        player4Hand2BetAmountTextDAO:SetText("H2: " .. player4SplitHand2NormalWinAmountValueDAO .. " G")

        player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")
    
        player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")
    
        player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4SplitHand2NormalWinAmountValueDAO)
        bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

        if player4BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player4PPBetTextDAO = dealerFrameDAO.player4PPBetLabelDAO:GetText()

        if player4PPBetTextDAO and player4PPBetTextDAO ~= "" then
            player4PPBetAmountValueDAO = tonumber(string.match(player4PPBetTextDAO, "%d+"))

            if player4PPBetAmountValueDAO then
                if player4PPSideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4PPBetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player4213BetTextDAO = dealerFrameDAO.player4213BetLabelDAO:GetText()

        if player4213BetTextDAO and player4213BetTextDAO ~= "" then
            player4213BetAmountValueDAO = tonumber(string.match(player4213BetTextDAO, "%d+"))
            
            if player4213BetAmountValueDAO then
                if player4213SideBetWinDAO == false then

                    player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4213BetAmountValueDAO)
                    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                    if player4BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

    end

    dealerFrameDAO.player4SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player4SplitHand2NormalWinCoinsDAO:Show()

end

-- Player 4 BJ Win
function player4BJWinDAO(messageDAO)
    player4MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4MainBetLabelDAO:GetText(), "%d+"))
    if player4MainBetAmountValueDAO then
        player4BJWinAmountValueDAO = player4MainBetAmountValueDAO * 2.5
        dealerFrameDAO.player4MainBetLabelDAO:SetText(player4BJWinAmountValueDAO .. " G")
        player4MainBetAmountTextDAO:SetText("Main Bet: " .. player4BJWinAmountValueDAO .. " G")
    end

    player4BJProfitvalueDAO = player4BJWinAmountValueDAO - player4MainBetAmountValueDAO

    player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4BJProfitvalueDAO)
    bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4BJProfitvalueDAO)
    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

    player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4BJWinAmountValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

    if player4BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player4PPBetTextDAO = dealerFrameDAO.player4PPBetLabelDAO:GetText()

    if player4PPBetTextDAO and player4PPBetTextDAO ~= "" then
        player4PPBetAmountValueDAO = tonumber(string.match(player4PPBetTextDAO, "%d+"))

        if player4PPBetAmountValueDAO then
            if player4PPSideBetWinDAO == false then

                player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4PPBetAmountValueDAO)
                bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4PPBetAmountValueDAO)
                bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                if player4BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    local player4213BetTextDAO = dealerFrameDAO.player4213BetLabelDAO:GetText()

    if player4213BetTextDAO and player4213BetTextDAO ~= "" then
        player4213BetAmountValueDAO = tonumber(string.match(player4213BetTextDAO, "%d+"))
        
        if player4213BetAmountValueDAO then
            if player4213SideBetWinDAO == false then

                player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4213BetAmountValueDAO)
                bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4213BetAmountValueDAO)
                bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                if player4BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

    dealerFrameDAO.player4NormalCoinsDAO:Hide()
    dealerFrameDAO.player4BJWinCoinsDAO:Show()

end

-- Player 4 Split Hand 1 BJ Win
function player4SplitH1BJDAO(messageDAO)
    player4SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1LabelDAO:GetText(), "%d+"))
    if player4SplitHand1BetAmountValueDAO then
        player4SplitHand1BJWinAmountValueDAO = player4SplitHand1BetAmountValueDAO * 2.5
        dealerFrameDAO.player4SplitHand1LabelDAO:SetText(player4SplitHand1BJWinAmountValueDAO .. " G")
        player4Hand1BetAmountTextDAO:SetText("H1: " .. player4SplitHand1BJWinAmountValueDAO .. " G")
    end

    player4SplitHand1BJProfitValueDAO = player4SplitHand1BJWinAmountValueDAO - player4SplitHand1BetAmountValueDAO

    player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4SplitHand1BJProfitValueDAO)
    bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4SplitHand1BJProfitValueDAO)
    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

    player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4SplitHand1BJWinAmountValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

    if player4BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player4PPBetTextDAO = dealerFrameDAO.player4PPBetLabelDAO:GetText()

    dealerFrameDAO.player4SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player4SplitHand1BJWinCoinsDAO:Show()

end

-- Player 4 Split Hand 2 BJ Win
function player4SplitH2BJDAO(messageDAO)
    player4SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2LabelDAO:GetText(), "%d+"))
    if player4SplitHand2BetAmountValueDAO then
        player4SplitHand2BJWinAmountValueDAO = player4SplitHand2BetAmountValueDAO * 2.5
        dealerFrameDAO.player4SplitHand2LabelDAO:SetText(player4SplitHand2BJWinAmountValueDAO .. " G")
        player4Hand2BetAmountTextDAO:SetText("H2: " .. player4SplitHand2BJWinAmountValueDAO .. " G")
    end

    player4SplitHand2BJProfitValueDAO = player4SplitHand2BJWinAmountValueDAO - player4SplitHand2BetAmountValueDAO

    player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4SplitHand2BJProfitValueDAO)
    bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4SplitHand2BJProfitValueDAO)
    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

    player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4SplitHand2BJWinAmountValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

    if player4BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player4PPBetTextDAO = dealerFrameDAO.player4PPBetLabelDAO:GetText()

    if player4PPBetTextDAO and player4PPBetTextDAO ~= "" then
        player4PPBetAmountValueDAO = tonumber(string.match(player4PPBetTextDAO, "%d+"))

        if player4PPBetAmountValueDAO then
            if player4PPSideBetWinDAO == false then

                player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4PPBetAmountValueDAO)
                bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4PPBetAmountValueDAO)
                bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                if player4BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    local player4213BetTextDAO = dealerFrameDAO.player4213BetLabelDAO:GetText()

    if player4213BetTextDAO and player4213BetTextDAO ~= "" then
        player4213BetAmountValueDAO = tonumber(string.match(player4213BetTextDAO, "%d+"))
        
        if player4213BetAmountValueDAO then
            if player4213SideBetWinDAO == false then

                player4BankingTotalLostDAO = player4BankingTotalLostDAO + tonumber(player4213BetAmountValueDAO)
                bankingFrameDAO.player4totalLostAmountDAO:SetText(player4BankingTotalLostDAO .. " G")

                player4BankingTotalProfitDAO = player4BankingTotalProfitDAO - tonumber(player4213BetAmountValueDAO)
                bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

                if player4BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    dealerFrameDAO.player4SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player4SplitHand2BJWinCoinsDAO:Show()

end

-- Player 4 Main Bet Complete Function
function player4HandleMainBetDAO(messageDAO)
    player4PlaceMainBetDAO()
    player4ActiveDAO = true
    local player4MainBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player4MainBetAmountValueDAO then
            player4PlaceMainBetTextDAO(player4MainBetAmountValueDAO)
            player4MainBetAmountTextDAO:SetText("Main Bet: " .. player4MainBetAmountValueDAO .. " G")
            player4TotalBetAmountDAO = player4TotalBetAmountDAO + tonumber(player4MainBetAmountValueDAO)
            player4TotalAmountTextDAO:SetText("Total: " .. player4TotalBetAmountDAO .. " G")
        else
    end

    player4BankingTotalWageredDAO = player4BankingTotalWageredDAO + tonumber(player4MainBetAmountValueDAO)
    bankingFrameDAO.player4totalWageredAmountDAO:SetText(player4BankingTotalWageredDAO .. " G")

    player4BankingBankrollDAO = player4BankingBankrollDAO - tonumber(player4MainBetAmountValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

end

-- Player 4 Double Bet Complete Function
function player4HandleDoubleBetDAO(messageDAO)
    player4PlaceDoubleBetDAO()
    local player4DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player4OriginalBetAmountValueDAO = tonumber(player4DoubleBetAmountValueDAO) / 2
    if player4DoubleBetAmountValueDAO then
        player4PlaceMainBetTextDAO(player4DoubleBetAmountValueDAO)
        player4MainBetAmountTextDAO:SetText("Main Bet: " .. player4DoubleBetAmountValueDAO .. " G")
        player4TotalBetAmountDAO = player4TotalBetAmountDAO + player4OriginalBetAmountValueDAO
        player4TotalAmountTextDAO:SetText("Total: " .. player4TotalBetAmountDAO .. " G")
    else
    end

    player4BankingTotalWageredDAO = player4BankingTotalWageredDAO + tonumber(player4OriginalBetAmountValueDAO)
    bankingFrameDAO.player4totalWageredAmountDAO:SetText(player4BankingTotalWageredDAO .. " G")

    player4BankingBankrollDAO = player4BankingBankrollDAO - tonumber(player4OriginalBetAmountValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

end

-- Player 4 Split Hand 1 Double Bet Complete Function
function player4SplitHand1DoubleBetDAO(messageDAO)
    
    dealerFrameDAO.player4SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player4SplitHand1DoubleCoinsDAO:Show()

    local player4SplitH1DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player4SplitH1OriginalBetAmountValueDAO = tonumber(player4SplitH1DoubleBetAmountValueDAO) / 2
    if player4SplitH1DoubleBetAmountValueDAO then
        dealerFrameDAO.player4SplitHand1LabelDAO:SetText(player4SplitH1DoubleBetAmountValueDAO .. " G")
        player4Hand1BetAmountTextDAO:SetText("H1: " .. player4SplitH1DoubleBetAmountValueDAO .. " G")
        player4TotalBetAmountDAO = player4TotalBetAmountDAO + player4SplitH1OriginalBetAmountValueDAO
        player4TotalAmountTextDAO:SetText("Total: " .. player4TotalBetAmountDAO .. " G")
    end

    player4BankingTotalWageredDAO = player4BankingTotalWageredDAO + tonumber(player4SplitH1OriginalBetAmountValueDAO)
    bankingFrameDAO.player4totalWageredAmountDAO:SetText(player4BankingTotalWageredDAO .. " G")

    player4BankingBankrollDAO = player4BankingBankrollDAO - tonumber(player4SplitH1OriginalBetAmountValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

end

-- Player 4 Split Hand 2 Double Bet Complete Function
function player4SplitHand2DoubleBetDAO(messageDAO)
    
    dealerFrameDAO.player4SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player4SplitHand2DoubleCoinsDAO:Show()

    local player4SplitH2DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player4SplitH2OriginalBetAmountValueDAO = tonumber(player4SplitH2DoubleBetAmountValueDAO) / 2
    if player4SplitH2DoubleBetAmountValueDAO then
        dealerFrameDAO.player4SplitHand2LabelDAO:SetText(player4SplitH2DoubleBetAmountValueDAO .. " G")
        player4Hand2BetAmountTextDAO:SetText("H2: " .. player4SplitH2DoubleBetAmountValueDAO .. " G")
        player4TotalBetAmountDAO = player4TotalBetAmountDAO + player4SplitH2OriginalBetAmountValueDAO
        player4TotalAmountTextDAO:SetText("Total: " .. player4TotalBetAmountDAO .. " G")
    end

    player4BankingTotalWageredDAO = player4BankingTotalWageredDAO + tonumber(player4SplitH2OriginalBetAmountValueDAO)
    bankingFrameDAO.player4totalWageredAmountDAO:SetText(player4BankingTotalWageredDAO .. " G")

    player4BankingBankrollDAO = player4BankingBankrollDAO - tonumber(player4SplitH2OriginalBetAmountValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

end

-- Player 4 Split Hand Bet Text
function player4SplitHand1BetTextDAO(AmountDAO)
    dealerFrameDAO.player4MainBetLabelDAO:Hide()
    dealerFrameDAO.player4MainBetLabelDAO:SetText("")
    dealerFrameDAO.player4SplitHand1LabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player4SplitHand1LabelDAO:Show()
    dealerFrameDAO.player4SplitHand2LabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player4SplitHand2LabelDAO:Show()
end

-- Player 4 Split Bet Image
function player4PlaceSplitBetDAO(messageDAO)
    dealerFrameDAO.player4NormalCoinsDAO:Hide()
    dealerFrameDAO.player4SplitHand2CoinsDAO:Show()
    dealerFrameDAO.player4SplitHand1CoinsDAO:Show()
end

-- Player 4 Place Initial Card ImagesDAO
function player4PlaceSplitCardsDAO(messageDAO)

    -- Players: 4
    if not player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[3]:Hide()
        player4cardName1DAO = dealtCardsDAO[1]
        player4cardName2DAO = dealtCardsDAO[3]
        turnDAO = 8 -- Player 4: 2nd Card (Split H1)

    -- Players: 1, 4
    elseif player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[2]:Hide()
        cardImagesDAO[5]:Hide()
        player4cardName1DAO = dealtCardsDAO[2]
        player4cardName2DAO = dealtCardsDAO[5]
        turnDAO = 30 -- Player 4: 2nd Card (Split H1)
    -- Players: 2, 4
    elseif not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[2]:Hide()
        cardImagesDAO[5]:Hide()
        player4cardName1DAO = dealtCardsDAO[2]
        player4cardName2DAO = dealtCardsDAO[5]
        turnDAO = 30 -- Player 4: 2nd Card (Split H1)
    -- Players: 3, 4
    elseif not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        cardImagesDAO[2]:Hide()
        cardImagesDAO[5]:Hide()
        player4cardName1DAO = dealtCardsDAO[2]
        player4cardName2DAO = dealtCardsDAO[5]
        turnDAO = 30 -- Player 4: 2nd Card (Split H1)
    -- Players: 4, 5
    elseif not player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[4]:Hide()
        player4cardName1DAO = dealtCardsDAO[1]
        player4cardName2DAO = dealtCardsDAO[4]
        turnDAO = 10 -- Player 4: 2nd Card (Split H1)

    -- Players: 1, 2, 4
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[7]:Hide()
        player4cardName1DAO = dealtCardsDAO[3]
        player4cardName2DAO = dealtCardsDAO[7]
        turnDAO = 52 -- Player 4: 2nd Card (Split H1)
    -- Players: 1, 3, 4
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[7]:Hide()
        player4cardName1DAO = dealtCardsDAO[3]
        player4cardName2DAO = dealtCardsDAO[7]
        turnDAO = 52 -- Player 4: 2nd Card (Split H1)
    -- Players: 1, 4, 5
    elseif player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[6]:Hide()
        player4cardName1DAO = dealtCardsDAO[2]
        player4cardName2DAO = dealtCardsDAO[6]
        turnDAO = 32 -- Player 4: 2nd Card (Split H1)
    -- Players: 2, 3, 4
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[7]:Hide()
        player4cardName1DAO = dealtCardsDAO[3]
        player4cardName2DAO = dealtCardsDAO[7]
        turnDAO = 52 -- Player 4: 2nd Card (Split H1)
    -- Players: 2, 4, 5
    elseif not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[6]:Hide()
        player4cardName1DAO = dealtCardsDAO[2]
        player4cardName2DAO = dealtCardsDAO[6]
        turnDAO = 32 -- Player 4: 2nd Card (Split H1)
    -- Players: 3, 4, 5
    elseif not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[2]:Hide()
        cardImagesDAO[6]:Hide()
        player4cardName1DAO = dealtCardsDAO[2]
        player4cardName2DAO = dealtCardsDAO[6]
        turnDAO = 32 -- Player 4: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then    
        cardImagesDAO[4]:Hide()
        cardImagesDAO[9]:Hide()
        player4cardName1DAO = dealtCardsDAO[4]
        player4cardName2DAO = dealtCardsDAO[9]
        turnDAO = 74 -- Player 4: 2nd Card (Split H1)
    -- Players: 1, 2, 4, 5
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[8]:Hide()
        player4cardName1DAO = dealtCardsDAO[3]
        player4cardName2DAO = dealtCardsDAO[8]
        turnDAO = 54 -- Player 4: 2nd Card (Split H1)
    -- Players: 1, 3, 4, 5
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[8]:Hide()
        player4cardName1DAO = dealtCardsDAO[3]
        player4cardName2DAO = dealtCardsDAO[8]
        turnDAO = 54 -- Player 4: 2nd Card (Split H1)
    -- Players: 2, 3, 4, 5
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[8]:Hide()
        player4cardName1DAO = dealtCardsDAO[3]
        player4cardName2DAO = dealtCardsDAO[8]
        turnDAO = 54 -- Player 4: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4, 5
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[4]:Hide()
        cardImagesDAO[10]:Hide()
        player4cardName1DAO = dealtCardsDAO[4]
        player4cardName2DAO = dealtCardsDAO[10]
        turnDAO = 76 -- Player 4: 2nd Card (Split H1)
    end

    player4cardImageFile1DAO = nil
    player4cardImageFile2DAO = nil

    for filenameDAO, cardDescriptionDAO in pairs(cardNamesDAO) do
        if cardDescriptionDAO == player4cardName1DAO then
            player4cardImageFile1DAO = filenameDAO
            break
        end
    end

    for filenameDAO, cardDescriptionDAO in pairs(cardNamesDAO) do
        if cardDescriptionDAO == player4cardName2DAO then
            player4cardImageFile2DAO = filenameDAO
            break
        end
    end

    player4NewCardImage1DAO = CreateFrame("Frame", nil, dealerFrameDAO)
    player4NewCardImage1DAO:SetSize(24, 48)
    player4NewCardImage1DAO:SetPoint("CENTER", dealerFrameDAO, 111, -9)
    player4NewCardImage1DAO.texture = player4NewCardImage1DAO:CreateTexture()
    player4NewCardImage1DAO.texture:SetAllPoints()
    player4NewCardImage1DAO.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. player4cardImageFile1DAO)
    player4NewCardImage1DAO:Show()

    player4NewCardImage2DAO = CreateFrame("Frame", nil, dealerFrameDAO)
    player4NewCardImage2DAO:SetSize(24, 48)
    player4NewCardImage2DAO:SetPoint("CENTER", dealerFrameDAO, 143, -18)
    player4NewCardImage2DAO.texture = player4NewCardImage2DAO:CreateTexture()
    player4NewCardImage2DAO.texture:SetAllPoints()
    player4NewCardImage2DAO.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. player4cardImageFile2DAO)
    player4NewCardImage2DAO:Show()

end

-- Player 4 Split Function
function player4HandleSplitDAO(messageDAO)
    player4PlaceSplitBetDAO()
    local player4MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player4MainBetLabelDAO:GetText(), "%d+"))
    if player4MainBetAmountValueDAO then
        player4SplitHand1BetTextDAO(player4MainBetAmountValueDAO)
        player4MainBetAmountTextDAO:Hide()
        player4Hand1BetAmountTextDAO:Show()
        player4Hand2BetAmountTextDAO:Show()
        player4Hand1BetAmountTextDAO:SetText("H1: " .. player4MainBetAmountValueDAO .. " G")
        player4Hand2BetAmountTextDAO:SetText("H2: " .. player4MainBetAmountValueDAO .. " G")
        player4TotalBetAmountDAO = player4TotalBetAmountDAO + player4MainBetAmountValueDAO
        player4TotalAmountTextDAO:SetText("Total: " .. player4TotalBetAmountDAO .. " G")
    else
    end 

    dealerFrameDAO.player4CardTotalTextDAO:SetText("")
    dealerFrameDAO.player4CardTotalTextDAO:Hide()

    if player4RunningTotalDAO == 2 then
        dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("1 or 11")
        dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("1 or 11")
        dealerFrameDAO.player4SplitHand1CardTotalTextDAO:Show()
        dealerFrameDAO.player4SplitHand2CardTotalTextDAO:Show()
    else
        dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText(player4S1RunningTotalDAO)
        dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText(player4S2RunningTotalDAO)
        dealerFrameDAO.player4SplitHand1CardTotalTextDAO:Show()
        dealerFrameDAO.player4SplitHand2CardTotalTextDAO:Show()
    end

    player4BankingTotalWageredDAO = player4BankingTotalWageredDAO + tonumber(player4MainBetAmountValueDAO)
    bankingFrameDAO.player4totalWageredAmountDAO:SetText(player4BankingTotalWageredDAO .. " G")

    player4BankingBankrollDAO = player4BankingBankrollDAO - tonumber(player4MainBetAmountValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")
    
    player4PlaceSplitCardsDAO()
    
end

-- Player 4 PP Bet Image
function player4PlacePPBetDAO(messageDAO)
    dealerFrameDAO.player4PPCoinsDAO:Show()
end

-- Player 4 PP Bet Text
function player4PlacePPBetTextDAO(AmountDAO)
    dealerFrameDAO.player4PPBetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player4PPBetLabelDAO:Show()
end

-- Player 4 PP Win
function player4PPWinDAO(messageDAO)
    dealerFrameDAO.player4PPCoinsDAO:Hide()
    dealerFrameDAO.player4PPWinCoinsDAO:Show()
    dealerFrameDAO.player4PPBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 181, 24)
end

-- Player 4 PP Bet Complete Function
function player4HandlePPBetDAO(messageDAO)
    player4PlacePPBetDAO()
    local player4PPBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player4PPBetAmountValueDAO then
            player4PlacePPBetTextDAO(player4PPBetAmountValueDAO)
            player4PPAmountTextDAO:SetText("PP Side Bet: " .. player4PPBetAmountValueDAO .. " G")
            player4TotalBetAmountDAO = player4TotalBetAmountDAO + tonumber(player4PPBetAmountValueDAO)
            player4TotalAmountTextDAO:SetText("Total: " .. player4TotalBetAmountDAO .. " G")
        else
    end

    player4BankingTotalWageredDAO = player4BankingTotalWageredDAO + tonumber(player4PPBetAmountValueDAO)
    bankingFrameDAO.player4totalWageredAmountDAO:SetText(player4BankingTotalWageredDAO .. " G")

    player4BankingBankrollDAO = player4BankingBankrollDAO - tonumber(player4PPBetAmountValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

end

-- Player 4 21+3 Bet Image
function player4Place213BetDAO(messageDAO)
    dealerFrameDAO.player4213CoinsDAO:Show()
end

-- Player 4 21+3 Bet Text
function player4Place213BetTextDAO(AmountDAO)
    dealerFrameDAO.player4213BetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player4213BetLabelDAO:Show()
end

-- Player 4 21+3 Win
function player4213WinDAO(messageDAO)
    dealerFrameDAO.player4213CoinsDAO:Hide()
    dealerFrameDAO.player4213WinCoinsDAO:Show()
    dealerFrameDAO.player4213BetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 97, 63)
end

-- Player 4 21+3 Bet Complete Function
function player4Handle213BetDAO(messageDAO)
    player4Place213BetDAO()
    local player4213BetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player4213BetAmountValueDAO then
            player4Place213BetTextDAO(player4213BetAmountValueDAO)
            player4213AmountTextDAO:SetText("21+3 Side Bet: " .. player4213BetAmountValueDAO .. " G")
            player4TotalBetAmountDAO = player4TotalBetAmountDAO + tonumber(player4213BetAmountValueDAO)
            player4TotalAmountTextDAO:SetText("Total: " .. player4TotalBetAmountDAO .. " G")
        else
    end

    player4BankingTotalWageredDAO = player4BankingTotalWageredDAO + tonumber(player4213BetAmountValueDAO)
    bankingFrameDAO.player4totalWageredAmountDAO:SetText(player4BankingTotalWageredDAO .. " G")

    player4BankingBankrollDAO = player4BankingBankrollDAO - tonumber(player4213BetAmountValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

end

function player4MixedPairWinDAO(messageDAO)
    player4PPSideBetWinDAO = true
    player4PPAmountTextValueDAO = tonumber(string.match(player4PPAmountTextDAO:GetText(), "%d+"))
    if player4PPAmountTextValueDAO then
        player4PPWinValueDAO = player4PPAmountTextValueDAO * mixedPairPayoutReturnDAO
        player4PPAmountTextDAO:SetText("PP Side Bet: " .. player4PPWinValueDAO .. " G")
        player4PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player4PPBetLabelDAO:SetText(player4PPWinValueDAO .. " G")
    end

    player4PPProfitValueDAO = player4PPWinValueDAO - player4PPAmountTextValueDAO

    player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4PPProfitValueDAO)
    bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4PPProfitValueDAO)
    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

    if player4BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4PPWinValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

    player4PPWinDAO()
end

function player4ColouredPairWinDAO(messageDAO)
    player4PPSideBetWinDAO = true
    player4PPAmountTextValueDAO = tonumber(string.match(player4PPAmountTextDAO:GetText(), "%d+"))
    if player4PPAmountTextValueDAO then
        player4PPWinValueDAO = player4PPAmountTextValueDAO * colouredPairPayoutReturnDAO
        player4PPAmountTextDAO:SetText("PP Side Bet: " .. player4PPWinValueDAO .. " G")
        player4PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player4PPBetLabelDAO:SetText(player4PPWinValueDAO .. " G")
    end

    player4PPProfitValueDAO = player4PPWinValueDAO - player4PPAmountTextValueDAO

    player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4PPProfitValueDAO)
    bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4PPProfitValueDAO)
    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

    if player4BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4PPWinValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

    player4PPWinDAO()
end

function player4PerfectPairWinDAO(messageDAO)
    player4PPSideBetWinDAO = true
    player4PPAmountTextValueDAO = tonumber(string.match(player4PPAmountTextDAO:GetText(), "%d+"))
    if player4PPAmountTextValueDAO then
        player4PPWinValueDAO = player4PPAmountTextValueDAO * perfectPairPayoutReturnDAO
        player4PPAmountTextDAO:SetText("PP Side Bet: " .. player4PPWinValueDAO .. " G")
        player4PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player4PPBetLabelDAO:SetText(player4PPWinValueDAO .. " G")
    end

    player4PPProfitValueDAO = player4PPWinValueDAO - player4PPAmountTextValueDAO

    player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4PPProfitValueDAO)
    bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4PPProfitValueDAO)
    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

    if player4BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4PPWinValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

    player4PPWinDAO()
end

function player4SuitedThreeOfAKindWinDAO(messageDAO)
    player4213SideBetWinDAO = true
    player4213AmountTextValueDAO = tonumber(string.match(player4213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player4213AmountTextValueDAO then
        player4213WinValueDAO = player4213AmountTextValueDAO * suitedThreeOfAKindPayoutReturnDAO
        player4213AmountTextDAO:SetText("21+3 Side Bet: " .. player4213WinValueDAO .. " G")
        player4213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player4213BetLabelDAO:SetText(player4213WinValueDAO .. " G")
    end

    player4213ProfitValueDAO = player4213WinValueDAO - player4213AmountTextValueDAO

    player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4213ProfitValueDAO)
    bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4213ProfitValueDAO)
    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

    if player4BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4213WinValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

    player4213WinDAO()
end

function player4StraightFlushWinDAO(messageDAO)
    player4213SideBetWinDAO = true
    player4213AmountTextValueDAO = tonumber(string.match(player4213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player4213AmountTextValueDAO then
        player4213WinValueDAO = player4213AmountTextValueDAO * straightFlushPayoutReturnDAO
        player4213AmountTextDAO:SetText("21+3 Side Bet: " .. player4213WinValueDAO .. " G")
        player4213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player4213BetLabelDAO:SetText(player4213WinValueDAO .. " G")
    end

    player4213ProfitValueDAO = player4213WinValueDAO - player4213AmountTextValueDAO

    player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4213ProfitValueDAO)
    bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4213ProfitValueDAO)
    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

    if player4BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4213WinValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

    player4213WinDAO()
end

function player4ThreeOfAKindWinDAO(messageDAO)
    player4213SideBetWinDAO = true
    player4213AmountTextValueDAO = tonumber(string.match(player4213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player4213AmountTextValueDAO then
        player4213WinValueDAO = player4213AmountTextValueDAO * threeOfAKindPayoutReturnDAO
        player4213AmountTextDAO:SetText("21+3 Side Bet: " .. player4213WinValueDAO .. " G")
        player4213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player4213BetLabelDAO:SetText(player4213WinValueDAO .. " G")
    end

    player4213ProfitValueDAO = player4213WinValueDAO - player4213AmountTextValueDAO

    player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4213ProfitValueDAO)
    bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4213ProfitValueDAO)
    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

    if player4BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4213WinValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

    player4213WinDAO()
end

function player4StraightWinDAO(messageDAO)
    player4213SideBetWinDAO = true
    player4213AmountTextValueDAO = tonumber(string.match(player4213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player4213AmountTextValueDAO then
        player4213WinValueDAO = player4213AmountTextValueDAO * straightPayoutReturnDAO
        player4213AmountTextDAO:SetText("21+3 Side Bet: " .. player4213WinValueDAO .. " G")
        player4213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player4213BetLabelDAO:SetText(player4213WinValueDAO .. " G")
    end

    player4213ProfitValueDAO = player4213WinValueDAO - player4213AmountTextValueDAO

    player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4213ProfitValueDAO)
    bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4213ProfitValueDAO)
    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

    if player4BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4213WinValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")

    player4213WinDAO()
end

function player4FlushWinDAO(messageDAO)
    player4213SideBetWinDAO = true
    player4213AmountTextValueDAO = tonumber(string.match(player4213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player4213AmountTextValueDAO then
        player4213WinValueDAO = player4213AmountTextValueDAO * flushPayoutReturnDAO
        player4213AmountTextDAO:SetText("21+3 Side Bet: " .. player4213WinValueDAO .. " G")
        player4213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player4213BetLabelDAO:SetText(player4213WinValueDAO .. " G")
    end

    player4213ProfitValueDAO = player4213WinValueDAO - player4213AmountTextValueDAO

    player4BankingTotalWonDAO = player4BankingTotalWonDAO + tonumber(player4213ProfitValueDAO)
    bankingFrameDAO.player4totalWonAmountDAO:SetText(player4BankingTotalWonDAO .. " G")

    player4BankingTotalProfitDAO = player4BankingTotalProfitDAO + tonumber(player4213ProfitValueDAO)
    bankingFrameDAO.player4totalProfitAmountDAO:SetText(player4BankingTotalProfitDAO .. " G")

    if player4BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player4totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player4BankingBankrollDAO = player4BankingBankrollDAO + tonumber(player4213WinValueDAO)
    bankingFrameDAO.player4BankrollAmountDAO:SetText(player4BankingBankrollDAO .. " G")
    
    player4213WinDAO()
end




























-- >>> PLAYER 5 <<<
-- >>> PLAYER 5 <<<
-- >>> PLAYER 5 <<<

-- Bet Amounts
-- Title for Player 5
player5TitleTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player5TitleTextDAO:SetPoint("CENTER", dealerFrameDAO, 338, 80)
player5TitleTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 12, "OUTLINE")
player5TitleTextDAO:SetJustifyH("CENTER")
player5TitleTextDAO:SetText("Player 5")
-- Player 5 character nameDAO
player5NameTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
player5NameTextDAO:SetPoint("CENTER", dealerFrameDAO, 338, 62)
player5NameTextDAO:SetText("Seat Empty")
player5NameTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")
-- Player 5 "Main Bet" amount text
player5MainBetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player5MainBetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 338, 43)
player5MainBetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player5MainBetAmountTextDAO:SetJustifyH("CENTER")
player5MainBetAmountTextDAO:SetText("Main Bet: N/A")
player5MainBetAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 5 "Hand 1 Bet" amount text
player5Hand1BetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player5Hand1BetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 302, 43)
player5Hand1BetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player5Hand1BetAmountTextDAO:SetJustifyH("CENTER")
player5Hand1BetAmountTextDAO:SetText("H1: N/A")
player5Hand1BetAmountTextDAO:SetTextColor(1, 1, 1)
player5Hand1BetAmountTextDAO:Hide()
-- Player 5 "Hand 2 Bet" amount text
player5Hand2BetAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player5Hand2BetAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 374, 43)
player5Hand2BetAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player5Hand2BetAmountTextDAO:SetJustifyH("CENTER")
player5Hand2BetAmountTextDAO:SetText("H2: N/A")
player5Hand2BetAmountTextDAO:SetTextColor(1, 1, 1)
player5Hand2BetAmountTextDAO:Hide()
-- Player 5 "Insurance Bet" amount text
player5InsuranceAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player5InsuranceAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 338, 32)
player5InsuranceAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player5InsuranceAmountTextDAO:SetJustifyH("CENTER")
player5InsuranceAmountTextDAO:SetText("Insurance: N/A")
player5InsuranceAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 5 "21+3 Side Bet" amount text
player5213AmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player5213AmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 338, 21)
player5213AmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player5213AmountTextDAO:SetJustifyH("CENTER")
player5213AmountTextDAO:SetText("21+3 Side Bet: N/A")
player5213AmountTextDAO:SetTextColor(1, 1, 1)
-- Player 5 "PP Side Bet" amount text
player5PPAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player5PPAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 338, 10)
player5PPAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player5PPAmountTextDAO:SetJustifyH("CENTER")
player5PPAmountTextDAO:SetText("PP Side Bet: N/A")
player5PPAmountTextDAO:SetTextColor(1, 1, 1)
-- Player 5 "Total Bet" amount text
player5TotalAmountTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontNormal")
player5TotalAmountTextDAO:SetPoint("CENTER", dealerFrameDAO, 338, -1)
player5TotalAmountTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 9, "OUTLINE")
player5TotalAmountTextDAO:SetJustifyH("CENTER")
player5TotalAmountTextDAO:SetText("Total: N/A")
player5TotalAmountTextDAO:SetTextColor(1, 1, 0.5)
-- Card Total for Player 5
dealerFrameDAO.player5CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player5CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", 297, -20)
dealerFrameDAO.player5CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player5CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player5CardTotalTextDAO:SetText("")
-- Card Total (Split Hand 1) for Player 5
dealerFrameDAO.player5SplitHand1CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", 275, 5)
dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("")
-- Card Total (Split Hand 2) for Player 5
dealerFrameDAO.player5SplitHand2CardTotalTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", 310, -35)
dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 18, "OUTLINE")
dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetJustifyH("CENTER")
dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("")

-- ImagesDAO for Player 5
-- Main Bet
dealerFrameDAO.player5NormalCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5NormalCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5NormalCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 245, -38)
dealerFrameDAO.player5NormalCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player5NormalCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5NormalCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5NormalCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5NormalCoinsDAO:Hide()
-- Split Bet Hand 1
dealerFrameDAO.player5SplitHand1CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5SplitHand1CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5SplitHand1CoinsDAO:SetPoint("CENTER", dealerFrameDAO, 225, -32)
dealerFrameDAO.player5SplitHand1CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player5SplitHand1CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5SplitHand1CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5SplitHand1CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5SplitHand1CoinsDAO:Hide()
-- Split Double Bet Hand 1
dealerFrameDAO.player5SplitHand1DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5SplitHand1DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5SplitHand1DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 225, -32)
dealerFrameDAO.player5SplitHand1DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player5SplitHand1DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5SplitHand1DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5SplitHand1DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5SplitHand1DoubleCoinsDAO:Hide()
-- Split Bet Hand 2
dealerFrameDAO.player5SplitHand2CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5SplitHand2CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5SplitHand2CoinsDAO:SetPoint("CENTER", dealerFrameDAO, 247, -53)
dealerFrameDAO.player5SplitHand2CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player5SplitHand2CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5SplitHand2CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5SplitHand2CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5SplitHand2CoinsDAO:Hide()
-- Split Double Bet Hand 2
dealerFrameDAO.player5SplitHand2DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5SplitHand2DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5SplitHand2DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 247, -53)
dealerFrameDAO.player5SplitHand2DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player5SplitHand2DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5SplitHand2DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5SplitHand2DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5SplitHand2DoubleCoinsDAO:Hide()
-- Double Bet
dealerFrameDAO.player5DoubleCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5DoubleCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5DoubleCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 245, -38)
dealerFrameDAO.player5DoubleCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player5DoubleCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5DoubleCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5DoubleCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5DoubleCoinsDAO:Hide()
-- PP Bet
dealerFrameDAO.player5PPCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5PPCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5PPCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 252, -100)
dealerFrameDAO.player5PPCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsHalfBet.tga")
dealerFrameDAO.player5PPCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5PPCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5PPCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5PPCoinsDAO:Hide()
-- 21+3 Bet
dealerFrameDAO.player5213CoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5213CoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5213CoinsDAO:SetPoint("CENTER", dealerFrameDAO, 204, -27)
dealerFrameDAO.player5213CoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsHalfBet.tga")
dealerFrameDAO.player5213CoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5213CoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5213CoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5213CoinsDAO:Hide()
-- Win
dealerFrameDAO.player5NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 245, -38)
dealerFrameDAO.player5NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player5NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5NormalWinCoinsDAO:Hide()
-- Split Win Hand 1
dealerFrameDAO.player5SplitHand1NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5SplitHand1NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5SplitHand1NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 225, -32)
dealerFrameDAO.player5SplitHand1NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player5SplitHand1NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5SplitHand1NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5SplitHand1NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5SplitHand1NormalWinCoinsDAO:Hide()
-- Split Win Hand 2
dealerFrameDAO.player5SplitHand2NormalWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5SplitHand2NormalWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5SplitHand2NormalWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 247, -53)
dealerFrameDAO.player5SplitHand2NormalWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsWin.tga")
dealerFrameDAO.player5SplitHand2NormalWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5SplitHand2NormalWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5SplitHand2NormalWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5SplitHand2NormalWinCoinsDAO:Hide()
-- Blackjack Win
dealerFrameDAO.player5BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 245, -38)
dealerFrameDAO.player5BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player5BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5BJWinCoinsDAO:Hide()
-- Split BJ Win Hand 1
dealerFrameDAO.player5SplitHand1BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5SplitHand1BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5SplitHand1BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 225, -32)
dealerFrameDAO.player5SplitHand1BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player5SplitHand1BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5SplitHand1BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5SplitHand1BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5SplitHand1BJWinCoinsDAO:Hide()
-- Split BJ Win Hand 2
dealerFrameDAO.player5SplitHand2BJWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5SplitHand2BJWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5SplitHand2BJWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 247, -53)
dealerFrameDAO.player5SplitHand2BJWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBJWin.tga")
dealerFrameDAO.player5SplitHand2BJWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5SplitHand2BJWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5SplitHand2BJWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5SplitHand2BJWinCoinsDAO:Hide()
-- PP Win
dealerFrameDAO.player5PPWinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5PPWinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5PPWinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 243, -95)
dealerFrameDAO.player5PPWinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player5PPWinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5PPWinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5PPWinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5PPWinCoinsDAO:Hide()
-- 21+3 Win
dealerFrameDAO.player5213WinCoinsDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
dealerFrameDAO.player5213WinCoinsDAO:SetSize(100, 100)
dealerFrameDAO.player5213WinCoinsDAO:SetPoint("CENTER", dealerFrameDAO, 195, -22)
dealerFrameDAO.player5213WinCoinsDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\CoinsBet.tga")
dealerFrameDAO.player5213WinCoinsDAO:SetBlendMode("BLEND")
dealerFrameDAO.player5213WinCoinsDAO:SetDrawLayer("OVERLAY")
dealerFrameDAO.player5213WinCoinsDAO:SetTexCoord(1, 0, 0, 1)
dealerFrameDAO.player5213WinCoinsDAO:Hide()

-- Labels for Player 5
-- Main Bet AmountDAO
dealerFrameDAO.player5MainBetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player5MainBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 263, -12)
dealerFrameDAO.player5MainBetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player5MainBetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Split Hand 1 Bet AmountDAO
dealerFrameDAO.player5SplitHand1LabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player5SplitHand1LabelDAO:SetPoint("CENTER", dealerFrameDAO, 242, -6)
dealerFrameDAO.player5SplitHand1LabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player5SplitHand1LabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Split Hand 2 Bet AmountDAO
dealerFrameDAO.player5SplitHand2LabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player5SplitHand2LabelDAO:SetPoint("CENTER", dealerFrameDAO, 264, -27)
dealerFrameDAO.player5SplitHand2LabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player5SplitHand2LabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Perfect Pairs AmountDAO
dealerFrameDAO.player5PPBetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player5PPBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 261, -82)
dealerFrameDAO.player5PPBetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player5PPBetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- 21+3 AmountDAO
dealerFrameDAO.player5213BetLabelDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlight")
dealerFrameDAO.player5213BetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 212, -9)
dealerFrameDAO.player5213BetLabelDAO:SetJustifyH("CENTER")
dealerFrameDAO.player5213BetLabelDAO:SetFont("Fonts\\FRIZQT__.TTF", 7, "OUTLINE")
-- Insurance YES for Player 5
player5InsuranceYesIconDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
player5InsuranceYesIconDAO:SetSize(14, 14)
player5InsuranceYesIconDAO:SetPoint("CENTER", dealerFrameDAO, 302, 79)
player5InsuranceYesIconDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\insuranceYes.tga")
player5InsuranceYesIconDAO:SetDrawLayer("OVERLAY")
player5InsuranceYesIconDAO:Hide()
-- Insurance NO for Player 5
player5InsuranceNoIconDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
player5InsuranceNoIconDAO:SetSize(14, 14)
player5InsuranceNoIconDAO:SetPoint("CENTER", dealerFrameDAO, 302, 79)
player5InsuranceNoIconDAO:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\insuranceNo.tga")
player5InsuranceNoIconDAO:SetDrawLayer("OVERLAY")
player5InsuranceNoIconDAO:Hide()

function player5HandleInsuranceYesDAO(messageDAO)
    player5InsuranceYesIconDAO:Show()
    player5InsuranceBetValueDAO = string.match(messageDAO, "(%d+)G")
    if player5InsuranceBetValueDAO then
        player5InsuranceAmountTextDAO:SetText("Insurance: " .. player5InsuranceBetValueDAO .. " G")
        player5TotalBetAmountDAO = player5TotalBetAmountDAO + player5InsuranceBetValueDAO
        player5TotalAmountTextDAO:SetText("Total: " .. player5TotalBetAmountDAO .. " G")
    end

    player5BankingTotalWageredDAO = player5BankingTotalWageredDAO + tonumber(player5InsuranceBetValueDAO)
    bankingFrameDAO.player5totalWageredAmountDAO:SetText(player5BankingTotalWageredDAO .. " G")

    player5BankingBankrollDAO = player5BankingBankrollDAO - tonumber(player5InsuranceBetValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

end

function player5InsuranceWinDAO(messageDAO)
    player5InsuranceBetAmountValueDAO = tonumber(string.match(player5InsuranceAmountTextDAO:GetText(), "%d+"))
    if player5InsuranceBetAmountValueDAO then
        player5InsuranceWinAmountValueDAO = player5InsuranceBetAmountValueDAO * 3

        player5InsuranceProfitValueDAO = player5InsuranceWinAmountValueDAO - player5InsuranceBetAmountValueDAO

        player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5InsuranceProfitValueDAO)
        bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

        player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5InsuranceProfitValueDAO)
        bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

        if player5BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end
        
        player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5InsuranceWinAmountValueDAO)
        bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

        player5InsuranceAmountTextDAO:SetText("Insurance: " .. player5InsuranceWinAmountValueDAO .. " G")
        player5InsuranceAmountTextDAO:SetTextColor(0, 1, 0)

    end

end

function player5InsuranceLossDAO(messageDAO)
    if player5InsuranceAmountTextDAO:GetText() == "Insurance: N/A" then
        print("")
    else
        player5InsuranceBetAmountValueDAO = tonumber(string.match(player5InsuranceAmountTextDAO:GetText(), "%d+"))
        if player5InsuranceBetAmountValueDAO then

            player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5InsuranceBetAmountValueDAO)
            bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

            player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5InsuranceBetAmountValueDAO)
            bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")
        end
    end
end

function player5HandleInsuranceNoDAO(messageDAO)
    player5InsuranceNoIconDAO:Show()
    player5InsuranceAmountTextDAO:SetText("Insurance: 0 G")
end

-- Player 5 Main Bet Image
function player5PlaceMainBetDAO(messageDAO)
    dealerFrameDAO.player5NormalCoinsDAO:Show()
end

-- Player 5 Main Bet Text
function player5PlaceMainBetTextDAO(AmountDAO)
    dealerFrameDAO.player5MainBetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player5MainBetLabelDAO:Show()
end

-- Player 5 Double Bet Image
function player5PlaceDoubleBetDAO(messageDAO)
    dealerFrameDAO.player5NormalCoinsDAO:Hide()
    dealerFrameDAO.player5DoubleCoinsDAO:Show()
end

-- Player 5 Push
function player5PushDAO(messageDAO)
    player5MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5MainBetLabelDAO:GetText(), "%d+"))
    if player5MainBetAmountValueDAO then

        dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5MainBetAmountValueDAO)
        bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

        local player5PPBetTextDAO = dealerFrameDAO.player5PPBetLabelDAO:GetText()

        if player5PPBetTextDAO and player5PPBetTextDAO ~= "" then
            player5PPBetAmountValueDAO = tonumber(string.match(player5PPBetTextDAO, "%d+"))
            
            if player5PPBetAmountValueDAO then
                if player5PPSideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player5213BetTextDAO = dealerFrameDAO.player5213BetLabelDAO:GetText()

        if player5213BetTextDAO and player5213BetTextDAO ~= "" then
            player5213BetAmountValueDAO = tonumber(string.match(player5213BetTextDAO, "%d+"))

            if player5213BetAmountValueDAO then
                if player5213SideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 5 Split Hand 1 Push
function player5SplitH1PushDAO()
    player5SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1LabelDAO:GetText(), "%d+"))
    if player5SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

    end
end

-- Player 5 Split Hand 2 Push
function player5SplitH2PushDAO()
    player5SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2LabelDAO:GetText(), "%d+"))
    if player5SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(0.2, 0.7, 1)

        player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

        local player5PPBetTextDAO = dealerFrameDAO.player5PPBetLabelDAO:GetText()

        if player5PPBetTextDAO and player5PPBetTextDAO ~= "" then
            player5PPBetAmountValueDAO = tonumber(string.match(player5PPBetTextDAO, "%d+"))
            
            if player5PPBetAmountValueDAO then
                if player5PPSideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player5213BetTextDAO = dealerFrameDAO.player5213BetLabelDAO:GetText()

        if player5213BetTextDAO and player5213BetTextDAO ~= "" then
            player5213BetAmountValueDAO = tonumber(string.match(player5213BetTextDAO, "%d+"))

            if player5213BetAmountValueDAO then
                if player5213SideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 5 Loss
function player5LossDAO(messageDAO)
    player5MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5MainBetLabelDAO:GetText(), "%d+"))
    if player5MainBetAmountValueDAO then

        dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)

        player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5MainBetAmountValueDAO)
        bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

        player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5MainBetAmountValueDAO)
        bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

        if player5BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player5PPBetTextDAO = dealerFrameDAO.player5PPBetLabelDAO:GetText()

        if player5PPBetTextDAO and player5PPBetTextDAO ~= "" then
            player5PPBetAmountValueDAO = tonumber(string.match(player5PPBetTextDAO, "%d+"))
            
            if player5PPBetAmountValueDAO then
                if player5PPSideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player5213BetTextDAO = dealerFrameDAO.player5213BetLabelDAO:GetText()

        if player5213BetTextDAO and player5213BetTextDAO ~= "" then
            player5213BetAmountValueDAO = tonumber(string.match(player5213BetTextDAO, "%d+"))

            if player5213BetAmountValueDAO then
                if player5213SideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 5 Split Hand 1 Loss
function player5SplitH1LossDAO()
    player5SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1LabelDAO:GetText(), "%d+"))
    if player5SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)

        player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

        player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

        if player5BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

    end

end

-- Player 5 Split Hand 2 Loss
function player5SplitH2LossDAO()
    player5SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2LabelDAO:GetText(), "%d+"))
    if player5SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)

        player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

        player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

        if player5BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player5PPBetTextDAO = dealerFrameDAO.player5PPBetLabelDAO:GetText()

        if player5PPBetTextDAO and player5PPBetTextDAO ~= "" then
            player5PPBetAmountValueDAO = tonumber(string.match(player5PPBetTextDAO, "%d+"))
            
            if player5PPBetAmountValueDAO then
                if player5PPSideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player5213BetTextDAO = dealerFrameDAO.player5213BetLabelDAO:GetText()

        if player5213BetTextDAO and player5213BetTextDAO ~= "" then
            player5213BetAmountValueDAO = tonumber(string.match(player5213BetTextDAO, "%d+"))

            if player5213BetAmountValueDAO then
                if player5213SideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end
    end
end

-- Player 5 Win
function player5WinDAO(messageDAO)
    player5MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5MainBetLabelDAO:GetText(), "%d+"))
    if player5MainBetAmountValueDAO then

        dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(0, 1, 0)

        player5NormalWinAmountValueDAO = player5MainBetAmountValueDAO * 2
        dealerFrameDAO.player5MainBetLabelDAO:SetText(player5NormalWinAmountValueDAO .. " G")
        player5MainBetAmountTextDAO:SetText("Main Bet: " .. player5NormalWinAmountValueDAO .. " G")

        player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5MainBetAmountValueDAO)
        bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

        player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5MainBetAmountValueDAO)
        bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

        player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5NormalWinAmountValueDAO)
        bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

        if player5BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player5PPBetTextDAO = dealerFrameDAO.player5PPBetLabelDAO:GetText()

        if player5PPBetTextDAO and player5PPBetTextDAO ~= "" then
            player5PPBetAmountValueDAO = tonumber(string.match(player5PPBetTextDAO, "%d+"))

            if player5PPBetAmountValueDAO then
                if player5PPSideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player5213BetTextDAO = dealerFrameDAO.player5213BetLabelDAO:GetText()

        if player5213BetTextDAO and player5213BetTextDAO ~= "" then
            player5213BetAmountValueDAO = tonumber(string.match(player5213BetTextDAO, "%d+"))
            
            if player5213BetAmountValueDAO then
                if player5213SideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

    end
    dealerFrameDAO.player5NormalCoinsDAO:Hide()
    dealerFrameDAO.player5NormalWinCoinsDAO:Show()
end

-- Player 5 Split Hand 1 Win
function player5SplitH1WinDAO(messageDAO)
    player5SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1LabelDAO:GetText(), "%d+"))
    if player5SplitHand1BetAmountValueDAO then

        dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(0, 1, 0)

        player5SplitHand1NormalWinAmountValueDAO = player5SplitHand1BetAmountValueDAO * 2
        dealerFrameDAO.player5SplitHand1LabelDAO:SetText(player5SplitHand1NormalWinAmountValueDAO .. " G")
        player5Hand1BetAmountTextDAO:SetText("H1: " .. player5SplitHand1NormalWinAmountValueDAO .. " G")

        player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")
    
        player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5SplitHand1BetAmountValueDAO)
        bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")
    
        player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5SplitHand1NormalWinAmountValueDAO)
        bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

        if player5BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

    end

    dealerFrameDAO.player5SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player5SplitHand1NormalWinCoinsDAO:Show()

end

-- Player 5 Split Hand 2 Win
function player5SplitH2WinDAO(messageDAO)
    player5SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2LabelDAO:GetText(), "%d+"))
    if player5SplitHand2BetAmountValueDAO then

        dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(0, 1, 0)

        player5SplitHand2NormalWinAmountValueDAO = player5SplitHand2BetAmountValueDAO * 2
        dealerFrameDAO.player5SplitHand2LabelDAO:SetText(player5SplitHand2NormalWinAmountValueDAO .. " G")
        player5Hand2BetAmountTextDAO:SetText("H2: " .. player5SplitHand2NormalWinAmountValueDAO .. " G")

        player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")
    
        player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5SplitHand2BetAmountValueDAO)
        bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")
    
        player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5SplitHand2NormalWinAmountValueDAO)
        bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

        if player5BankingTotalProfitDAO >= 0 then
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
        else
            bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
        end

        local player5PPBetTextDAO = dealerFrameDAO.player5PPBetLabelDAO:GetText()

        if player5PPBetTextDAO and player5PPBetTextDAO ~= "" then
            player5PPBetAmountValueDAO = tonumber(string.match(player5PPBetTextDAO, "%d+"))

            if player5PPBetAmountValueDAO then
                if player5PPSideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5PPBetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

        local player5213BetTextDAO = dealerFrameDAO.player5213BetLabelDAO:GetText()

        if player5213BetTextDAO and player5213BetTextDAO ~= "" then
            player5213BetAmountValueDAO = tonumber(string.match(player5213BetTextDAO, "%d+"))
            
            if player5213BetAmountValueDAO then
                if player5213SideBetWinDAO == false then

                    player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5213BetAmountValueDAO)
                    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                    if player5BankingTotalProfitDAO >= 0 then
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                    else
                        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                    end

                end
            end
        end

    end

    dealerFrameDAO.player5SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player5SplitHand2NormalWinCoinsDAO:Show()

end

-- Player 5 BJ Win
function player5BJWinDAO(messageDAO)
    player5MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5MainBetLabelDAO:GetText(), "%d+"))
    if player5MainBetAmountValueDAO then
        player5BJWinAmountValueDAO = player5MainBetAmountValueDAO * 2.5
        dealerFrameDAO.player5MainBetLabelDAO:SetText(player5BJWinAmountValueDAO .. " G")
        player5MainBetAmountTextDAO:SetText("Main Bet: " .. player5BJWinAmountValueDAO .. " G")
    end

    player5BJProfitvalueDAO = player5BJWinAmountValueDAO - player5MainBetAmountValueDAO

    player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5BJProfitvalueDAO)
    bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5BJProfitvalueDAO)
    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

    player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5BJWinAmountValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

    if player5BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player5PPBetTextDAO = dealerFrameDAO.player5PPBetLabelDAO:GetText()

    if player5PPBetTextDAO and player5PPBetTextDAO ~= "" then
        player5PPBetAmountValueDAO = tonumber(string.match(player5PPBetTextDAO, "%d+"))

        if player5PPBetAmountValueDAO then
            if player5PPSideBetWinDAO == false then

                player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5PPBetAmountValueDAO)
                bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5PPBetAmountValueDAO)
                bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                if player5BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    local player5213BetTextDAO = dealerFrameDAO.player5213BetLabelDAO:GetText()

    if player5213BetTextDAO and player5213BetTextDAO ~= "" then
        player5213BetAmountValueDAO = tonumber(string.match(player5213BetTextDAO, "%d+"))
        
        if player5213BetAmountValueDAO then
            if player5213SideBetWinDAO == false then

                player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5213BetAmountValueDAO)
                bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5213BetAmountValueDAO)
                bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                if player5BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

    dealerFrameDAO.player5NormalCoinsDAO:Hide()
    dealerFrameDAO.player5BJWinCoinsDAO:Show()

end

-- Player 5 Split Hand 1 BJ Win
function player5SplitH1BJDAO(messageDAO)
    player5SplitHand1BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1LabelDAO:GetText(), "%d+"))
    if player5SplitHand1BetAmountValueDAO then
        player5SplitHand1BJWinAmountValueDAO = player5SplitHand1BetAmountValueDAO * 2.5
        dealerFrameDAO.player5SplitHand1LabelDAO:SetText(player5SplitHand1BJWinAmountValueDAO .. " G")
        player5Hand1BetAmountTextDAO:SetText("H1: " .. player5SplitHand1BJWinAmountValueDAO .. " G")
    end

    player5SplitHand1BJProfitValueDAO = player5SplitHand1BJWinAmountValueDAO - player5SplitHand1BetAmountValueDAO

    player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5SplitHand1BJProfitValueDAO)
    bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5SplitHand1BJProfitValueDAO)
    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

    player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5SplitHand1BJWinAmountValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

    if player5BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player5PPBetTextDAO = dealerFrameDAO.player5PPBetLabelDAO:GetText()

    dealerFrameDAO.player5SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player5SplitHand1BJWinCoinsDAO:Show()

end

-- Player 5 Split Hand 2 BJ Win
function player5SplitH2BJDAO(messageDAO)
    player5SplitHand2BetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2LabelDAO:GetText(), "%d+"))
    if player5SplitHand2BetAmountValueDAO then
        player5SplitHand2BJWinAmountValueDAO = player5SplitHand2BetAmountValueDAO * 2.5
        dealerFrameDAO.player5SplitHand2LabelDAO:SetText(player5SplitHand2BJWinAmountValueDAO .. " G")
        player5Hand2BetAmountTextDAO:SetText("H2: " .. player5SplitHand2BJWinAmountValueDAO .. " G")
    end

    player5SplitHand2BJProfitValueDAO = player5SplitHand2BJWinAmountValueDAO - player5SplitHand2BetAmountValueDAO

    player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5SplitHand2BJProfitValueDAO)
    bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5SplitHand2BJProfitValueDAO)
    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

    player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5SplitHand2BJWinAmountValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

    if player5BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    local player5PPBetTextDAO = dealerFrameDAO.player5PPBetLabelDAO:GetText()

    if player5PPBetTextDAO and player5PPBetTextDAO ~= "" then
        player5PPBetAmountValueDAO = tonumber(string.match(player5PPBetTextDAO, "%d+"))

        if player5PPBetAmountValueDAO then
            if player5PPSideBetWinDAO == false then

                player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5PPBetAmountValueDAO)
                bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5PPBetAmountValueDAO)
                bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                if player5BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    local player5213BetTextDAO = dealerFrameDAO.player5213BetLabelDAO:GetText()

    if player5213BetTextDAO and player5213BetTextDAO ~= "" then
        player5213BetAmountValueDAO = tonumber(string.match(player5213BetTextDAO, "%d+"))
        
        if player5213BetAmountValueDAO then
            if player5213SideBetWinDAO == false then

                player5BankingTotalLostDAO = player5BankingTotalLostDAO + tonumber(player5213BetAmountValueDAO)
                bankingFrameDAO.player5totalLostAmountDAO:SetText(player5BankingTotalLostDAO .. " G")

                player5BankingTotalProfitDAO = player5BankingTotalProfitDAO - tonumber(player5213BetAmountValueDAO)
                bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

                if player5BankingTotalProfitDAO >= 0 then
                    bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
                else
                    bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
                end

            end
        end
    end

    dealerFrameDAO.player5SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player5SplitHand2BJWinCoinsDAO:Show()

end

-- Player 5 Main Bet Complete Function
function player5HandleMainBetDAO(messageDAO)
    player5PlaceMainBetDAO()
    player5ActiveDAO = true
    local player5MainBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player5MainBetAmountValueDAO then
            player5PlaceMainBetTextDAO(player5MainBetAmountValueDAO)
            player5MainBetAmountTextDAO:SetText("Main Bet: " .. player5MainBetAmountValueDAO .. " G")
            player5TotalBetAmountDAO = player5TotalBetAmountDAO + tonumber(player5MainBetAmountValueDAO)
            player5TotalAmountTextDAO:SetText("Total: " .. player5TotalBetAmountDAO .. " G")
        else
    end

    player5BankingTotalWageredDAO = player5BankingTotalWageredDAO + tonumber(player5MainBetAmountValueDAO)
    bankingFrameDAO.player5totalWageredAmountDAO:SetText(player5BankingTotalWageredDAO .. " G")

    player5BankingBankrollDAO = player5BankingBankrollDAO - tonumber(player5MainBetAmountValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

end

-- Player 5 Double Bet Complete Function
function player5HandleDoubleBetDAO(messageDAO)
    player5PlaceDoubleBetDAO()
    local player5DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player5OriginalBetAmountValueDAO = tonumber(player5DoubleBetAmountValueDAO) / 2
    if player5DoubleBetAmountValueDAO then
        player5PlaceMainBetTextDAO(player5DoubleBetAmountValueDAO)
        player5MainBetAmountTextDAO:SetText("Main Bet: " .. player5DoubleBetAmountValueDAO .. " G")
        player5TotalBetAmountDAO = player5TotalBetAmountDAO + player5OriginalBetAmountValueDAO
        player5TotalAmountTextDAO:SetText("Total: " .. player5TotalBetAmountDAO .. " G")
    else
    end

    player5BankingTotalWageredDAO = player5BankingTotalWageredDAO + tonumber(player5OriginalBetAmountValueDAO)
    bankingFrameDAO.player5totalWageredAmountDAO:SetText(player5BankingTotalWageredDAO .. " G")

    player5BankingBankrollDAO = player5BankingBankrollDAO - tonumber(player5OriginalBetAmountValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

end

-- Player 5 Split Hand 1 Double Bet Complete Function
function player5SplitHand1DoubleBetDAO(messageDAO)
    
    dealerFrameDAO.player5SplitHand1CoinsDAO:Hide()
    dealerFrameDAO.player5SplitHand1DoubleCoinsDAO:Show()

    local player5SplitH1DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player5SplitH1OriginalBetAmountValueDAO = tonumber(player5SplitH1DoubleBetAmountValueDAO) / 2
    if player5SplitH1DoubleBetAmountValueDAO then
        dealerFrameDAO.player5SplitHand1LabelDAO:SetText(player5SplitH1DoubleBetAmountValueDAO .. " G")
        player5Hand1BetAmountTextDAO:SetText("H1: " .. player5SplitH1DoubleBetAmountValueDAO .. " G")
        player5TotalBetAmountDAO = player5TotalBetAmountDAO + player5SplitH1OriginalBetAmountValueDAO
        player5TotalAmountTextDAO:SetText("Total: " .. player5TotalBetAmountDAO .. " G")
    end

    player5BankingTotalWageredDAO = player5BankingTotalWageredDAO + tonumber(player5SplitH1OriginalBetAmountValueDAO)
    bankingFrameDAO.player5totalWageredAmountDAO:SetText(player5BankingTotalWageredDAO .. " G")

    player5BankingBankrollDAO = player5BankingBankrollDAO - tonumber(player5SplitH1OriginalBetAmountValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

end

-- Player 5 Split Hand 2 Double Bet Complete Function
function player5SplitHand2DoubleBetDAO(messageDAO)
    
    dealerFrameDAO.player5SplitHand2CoinsDAO:Hide()
    dealerFrameDAO.player5SplitHand2DoubleCoinsDAO:Show()

    local player5SplitH2DoubleBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
    local player5SplitH2OriginalBetAmountValueDAO = tonumber(player5SplitH2DoubleBetAmountValueDAO) / 2
    if player5SplitH2DoubleBetAmountValueDAO then
        dealerFrameDAO.player5SplitHand2LabelDAO:SetText(player5SplitH2DoubleBetAmountValueDAO .. " G")
        player5Hand2BetAmountTextDAO:SetText("H2: " .. player5SplitH2DoubleBetAmountValueDAO .. " G")
        player5TotalBetAmountDAO = player5TotalBetAmountDAO + player5SplitH2OriginalBetAmountValueDAO
        player5TotalAmountTextDAO:SetText("Total: " .. player5TotalBetAmountDAO .. " G")
    end

    player5BankingTotalWageredDAO = player5BankingTotalWageredDAO + tonumber(player5SplitH2OriginalBetAmountValueDAO)
    bankingFrameDAO.player5totalWageredAmountDAO:SetText(player5BankingTotalWageredDAO .. " G")

    player5BankingBankrollDAO = player5BankingBankrollDAO - tonumber(player5SplitH2OriginalBetAmountValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

end

-- Player 5 Split Hand Bet Text
function player5SplitHand1BetTextDAO(AmountDAO)
    dealerFrameDAO.player5MainBetLabelDAO:Hide()
    dealerFrameDAO.player5MainBetLabelDAO:SetText("")
    dealerFrameDAO.player5SplitHand1LabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player5SplitHand1LabelDAO:Show()
    dealerFrameDAO.player5SplitHand2LabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player5SplitHand2LabelDAO:Show()
end

-- Player 5 Split Bet Image
function player5PlaceSplitBetDAO(messageDAO)
    dealerFrameDAO.player5NormalCoinsDAO:Hide()
    dealerFrameDAO.player5SplitHand2CoinsDAO:Show()
    dealerFrameDAO.player5SplitHand1CoinsDAO:Show()
end

-- Player 5 Place Initial Card ImagesDAO
function player5PlaceSplitCardsDAO(messageDAO)

    -- Players: 5
    if not player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        cardImagesDAO[1]:Hide()
        cardImagesDAO[3]:Hide()
        player5cardName1DAO = dealtCardsDAO[1]
        player5cardName2DAO = dealtCardsDAO[3]
        turnDAO = 8 -- Player 5: 2nd Card (Split H1)

    -- Players: 1, 5
    elseif player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        cardImagesDAO[2]:Hide()
        cardImagesDAO[5]:Hide()
        player5cardName1DAO = dealtCardsDAO[2]
        player5cardName2DAO = dealtCardsDAO[5]
        turnDAO = 30 -- Player 5: 2nd Card (Split H1)
    -- Players: 2, 5
    elseif not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        cardImagesDAO[2]:Hide()
        cardImagesDAO[5]:Hide()
        player5cardName1DAO = dealtCardsDAO[2]
        player5cardName2DAO = dealtCardsDAO[5]
        turnDAO = 30 -- Player 5: 2nd Card (Split H1)
    -- Players: 3, 5
    elseif not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        cardImagesDAO[2]:Hide()
        cardImagesDAO[5]:Hide()
        player5cardName1DAO = dealtCardsDAO[2]
        player5cardName2DAO = dealtCardsDAO[5]
        turnDAO = 30 -- Player 5: 2nd Card (Split H1)
    -- Players: 4, 5
    elseif not player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then
        cardImagesDAO[2]:Hide()
        cardImagesDAO[5]:Hide()
        player5cardName1DAO = dealtCardsDAO[2]
        player5cardName2DAO = dealtCardsDAO[5]
        turnDAO = 30 -- Player 5: 2nd Card (Split H1)

    -- Players: 1, 2, 5
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[7]:Hide()
        player5cardName1DAO = dealtCardsDAO[3]
        player5cardName2DAO = dealtCardsDAO[7]
        turnDAO = 52 -- Player 5: 2nd Card (Split H1)
    -- Players: 1, 3, 5
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[7]:Hide()
        player5cardName1DAO = dealtCardsDAO[3]
        player5cardName2DAO = dealtCardsDAO[7]
        turnDAO = 52 -- Player 5: 2nd Card (Split H1)
    -- Players: 1, 4, 5
    elseif player1ActiveDAO and not player2ActiveDAO and notPlayer3Active and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[7]:Hide()
        player5cardName1DAO = dealtCardsDAO[3]
        player5cardName2DAO = dealtCardsDAO[7]
        turnDAO = 52 -- Player 5: 2nd Card (Split H1)
    -- Players: 2, 3, 5
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[7]:Hide()
        player5cardName1DAO = dealtCardsDAO[3]
        player5cardName2DAO = dealtCardsDAO[7]
        turnDAO = 52 -- Player 5: 2nd Card (Split H1)
    -- Players: 2, 4, 5
    elseif not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[7]:Hide()
        player5cardName1DAO = dealtCardsDAO[3]
        player5cardName2DAO = dealtCardsDAO[7]
        turnDAO = 52 -- Player 5: 2nd Card (Split H1)
    -- Players: 3, 4, 5
    elseif not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[3]:Hide()
        cardImagesDAO[7]:Hide()
        player5cardName1DAO = dealtCardsDAO[3]
        player5cardName2DAO = dealtCardsDAO[7]
        turnDAO = 52 -- Player 5: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 5
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[4]:Hide()
        cardImagesDAO[9]:Hide()
        player5cardName1DAO = dealtCardsDAO[4]
        player5cardName2DAO = dealtCardsDAO[9]
        turnDAO = 74 -- Player 5: 2nd Card (Split H1)
    -- Players: 1, 2, 4, 5
    elseif player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[4]:Hide()
        cardImagesDAO[9]:Hide()
        player5cardName1DAO = dealtCardsDAO[4]
        player5cardName2DAO = dealtCardsDAO[9]
        turnDAO = 74 -- Player 5: 2nd Card (Split H1)
    -- Players: 1, 3, 4, 5
    elseif player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[4]:Hide()
        cardImagesDAO[9]:Hide()
        player5cardName1DAO = dealtCardsDAO[4]
        player5cardName2DAO = dealtCardsDAO[9]
        turnDAO = 74 -- Player 5: 2nd Card (Split H1)
    -- Players: 2, 3, 4, 5
    elseif not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[4]:Hide()
        cardImagesDAO[9]:Hide()
        player5cardName1DAO = dealtCardsDAO[4]
        player5cardName2DAO = dealtCardsDAO[9]
        turnDAO = 74 -- Player 5: 2nd Card (Split H1)

    -- Players: 1, 2, 3, 4, 5
    elseif player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then    
        cardImagesDAO[5]:Hide()
        cardImagesDAO[11]:Hide()
        player5cardName1DAO = dealtCardsDAO[5]
        player5cardName2DAO = dealtCardsDAO[11]
        turnDAO = 96 -- Player 5: 2nd Card (Split H1)
    end

    player5cardImageFile1DAO = nil
    player5cardImageFile2DAO = nil

    for filenameDAO, cardDescriptionDAO in pairs(cardNamesDAO) do
        if cardDescriptionDAO == player5cardName1DAO then
            player5cardImageFile1DAO = filenameDAO
            break
        end
    end

    for filenameDAO, cardDescriptionDAO in pairs(cardNamesDAO) do
        if cardDescriptionDAO == player5cardName2DAO then
            player5cardImageFile2DAO = filenameDAO
            break
        end
    end

    player5NewCardImage1DAO = CreateFrame("Frame", nil, dealerFrameDAO)
    player5NewCardImage1DAO:SetSize(24, 48)
    player5NewCardImage1DAO:SetPoint("CENTER", dealerFrameDAO, 200, -70)
    player5NewCardImage1DAO.texture = player5NewCardImage1DAO:CreateTexture()
    player5NewCardImage1DAO.texture:SetAllPoints()
    player5NewCardImage1DAO.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. player5cardImageFile1DAO)
    player5NewCardImage1DAO:Show()

    player5NewCardImage2DAO = CreateFrame("Frame", nil, dealerFrameDAO)
    player5NewCardImage2DAO:SetSize(24, 48)
    player5NewCardImage2DAO:SetPoint("CENTER", dealerFrameDAO, 230, -105)
    player5NewCardImage2DAO.texture = player5NewCardImage2DAO:CreateTexture()
    player5NewCardImage2DAO.texture:SetAllPoints()
    player5NewCardImage2DAO.texture:SetTexture("Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. player5cardImageFile2DAO)
    player5NewCardImage2DAO:Show()

end

-- Player 5 Split Function
function player5HandleSplitDAO(messageDAO)
    player5PlaceSplitBetDAO()
    local player5MainBetAmountValueDAO = tonumber(string.match(dealerFrameDAO.player5MainBetLabelDAO:GetText(), "%d+"))
    if player5MainBetAmountValueDAO then
        player5SplitHand1BetTextDAO(player5MainBetAmountValueDAO)
        player5MainBetAmountTextDAO:Hide()
        player5Hand1BetAmountTextDAO:Show()
        player5Hand2BetAmountTextDAO:Show()
        player5Hand1BetAmountTextDAO:SetText("H1: " .. player5MainBetAmountValueDAO .. " G")
        player5Hand2BetAmountTextDAO:SetText("H2: " .. player5MainBetAmountValueDAO .. " G")
        player5TotalBetAmountDAO = player5TotalBetAmountDAO + player5MainBetAmountValueDAO
        player5TotalAmountTextDAO:SetText("Total: " .. player5TotalBetAmountDAO .. " G")
    else
    end 

    dealerFrameDAO.player5CardTotalTextDAO:SetText("")
    dealerFrameDAO.player5CardTotalTextDAO:Hide()

    if player5RunningTotalDAO == 2 then
        dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("1 or 11")
        dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("1 or 11")
        dealerFrameDAO.player5SplitHand1CardTotalTextDAO:Show()
        dealerFrameDAO.player5SplitHand2CardTotalTextDAO:Show()
    else
        dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText(player5S1RunningTotalDAO)
        dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText(player5S2RunningTotalDAO)
        dealerFrameDAO.player5SplitHand1CardTotalTextDAO:Show()
        dealerFrameDAO.player5SplitHand2CardTotalTextDAO:Show()
    end

    player5BankingTotalWageredDAO = player5BankingTotalWageredDAO + tonumber(player5MainBetAmountValueDAO)
    bankingFrameDAO.player5totalWageredAmountDAO:SetText(player5BankingTotalWageredDAO .. " G")

    player5BankingBankrollDAO = player5BankingBankrollDAO - tonumber(player5MainBetAmountValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")
    
    player5PlaceSplitCardsDAO()
   
end

-- Player 5 PP Bet Image
function player5PlacePPBetDAO(messageDAO)
    dealerFrameDAO.player5PPCoinsDAO:Show()
end

-- Player 5 PP Bet Text
function player5PlacePPBetTextDAO(AmountDAO)
    dealerFrameDAO.player5PPBetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player5PPBetLabelDAO:Show()
end

-- Player 5 PP Win
function player5PPWinDAO(messageDAO)
    dealerFrameDAO.player5PPCoinsDAO:Hide()
    dealerFrameDAO.player5PPWinCoinsDAO:Show()
    dealerFrameDAO.player5PPBetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 261, -70)
end

-- Player 5 PP Bet Complete Function
function player5HandlePPBetDAO(messageDAO)
    player5PlacePPBetDAO()
    local player5PPBetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player5PPBetAmountValueDAO then
            player5PlacePPBetTextDAO(player5PPBetAmountValueDAO)
            player5PPAmountTextDAO:SetText("PP Side Bet: " .. player5PPBetAmountValueDAO .. " G")
            player5TotalBetAmountDAO = player5TotalBetAmountDAO + tonumber(player5PPBetAmountValueDAO)
            player5TotalAmountTextDAO:SetText("Total: " .. player5TotalBetAmountDAO .. " G")
        else
    end

    player5BankingTotalWageredDAO = player5BankingTotalWageredDAO + tonumber(player5PPBetAmountValueDAO)
    bankingFrameDAO.player5totalWageredAmountDAO:SetText(player5BankingTotalWageredDAO .. " G")

    player5BankingBankrollDAO = player5BankingBankrollDAO - tonumber(player5PPBetAmountValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

end

-- Player 5 21+3 Bet Image
function player5Place213BetDAO(messageDAO)
    dealerFrameDAO.player5213CoinsDAO:Show()
end

-- Player 5 21+3 Bet Text
function player5Place213BetTextDAO(AmountDAO)
    dealerFrameDAO.player5213BetLabelDAO:SetText(AmountDAO .. " G")
    dealerFrameDAO.player5213BetLabelDAO:Show()
end

-- Player 5 21+3 Win
function player5213WinDAO(messageDAO)
    dealerFrameDAO.player5213CoinsDAO:Hide()
    dealerFrameDAO.player5213WinCoinsDAO:Show()
    dealerFrameDAO.player5213BetLabelDAO:SetPoint("CENTER", dealerFrameDAO, 212, 4)
end

-- Player 5 21+3 Bet Complete Function
function player5Handle213BetDAO(messageDAO)
    player5Place213BetDAO()
    local player5213BetAmountValueDAO = string.match(messageDAO, "(%d+)G")
        if player5213BetAmountValueDAO then
            player5Place213BetTextDAO(player5213BetAmountValueDAO)
            player5213AmountTextDAO:SetText("21+3 Side Bet: " .. player5213BetAmountValueDAO .. " G")
            player5TotalBetAmountDAO = player5TotalBetAmountDAO + tonumber(player5213BetAmountValueDAO)
            player5TotalAmountTextDAO:SetText("Total: " .. player5TotalBetAmountDAO .. " G")
        else
    end

    player5BankingTotalWageredDAO = player5BankingTotalWageredDAO + tonumber(player5213BetAmountValueDAO)
    bankingFrameDAO.player5totalWageredAmountDAO:SetText(player5BankingTotalWageredDAO .. " G")

    player5BankingBankrollDAO = player5BankingBankrollDAO - tonumber(player5213BetAmountValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

end

function player5MixedPairWinDAO(messageDAO)
    player5PPSideBetWinDAO = true
    player5PPAmountTextValueDAO = tonumber(string.match(player5PPAmountTextDAO:GetText(), "%d+"))
    if player5PPAmountTextValueDAO then
        player5PPWinValueDAO = player5PPAmountTextValueDAO * mixedPairPayoutReturnDAO
        player5PPAmountTextDAO:SetText("PP Side Bet: " .. player5PPWinValueDAO .. " G")
        player5PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player5PPBetLabelDAO:SetText(player5PPWinValueDAO .. " G")
    end

    player5PPProfitValueDAO = player5PPWinValueDAO - player5PPAmountTextValueDAO

    player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5PPProfitValueDAO)
    bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5PPProfitValueDAO)
    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

    if player5BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5PPWinValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

    player5PPWinDAO()
end

function player5ColouredPairWinDAO(messageDAO)
    player5PPSideBetWinDAO = true
    player5PPAmountTextValueDAO = tonumber(string.match(player5PPAmountTextDAO:GetText(), "%d+"))
    if player5PPAmountTextValueDAO then
        player5PPWinValueDAO = player5PPAmountTextValueDAO * colouredPairPayoutReturnDAO
        player5PPAmountTextDAO:SetText("PP Side Bet: " .. player5PPWinValueDAO .. " G")
        player5PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player5PPBetLabelDAO:SetText(player5PPWinValueDAO .. " G")
    end

    player5PPProfitValueDAO = player5PPWinValueDAO - player5PPAmountTextValueDAO

    player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5PPProfitValueDAO)
    bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5PPProfitValueDAO)
    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

    if player5BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5PPWinValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

    player5PPWinDAO()
end

function player5PerfectPairWinDAO(messageDAO)
    player5PPSideBetWinDAO = true
    player5PPAmountTextValueDAO = tonumber(string.match(player5PPAmountTextDAO:GetText(), "%d+"))
    if player5PPAmountTextValueDAO then
        player5PPWinValueDAO = player5PPAmountTextValueDAO * perfectPairPayoutReturnDAO
        player5PPAmountTextDAO:SetText("PP Side Bet: " .. player5PPWinValueDAO .. " G")
        player5PPAmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player5PPBetLabelDAO:SetText(player5PPWinValueDAO .. " G")
    end

    player5PPProfitValueDAO = player5PPWinValueDAO - player5PPAmountTextValueDAO

    player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5PPProfitValueDAO)
    bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5PPProfitValueDAO)
    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

    if player5BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end

    player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5PPWinValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

    player5PPWinDAO()
end

function player5SuitedThreeOfAKindWinDAO(messageDAO)
    player5213SideBetWinDAO = true
    player5213AmountTextValueDAO = tonumber(string.match(player5213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player5213AmountTextValueDAO then
        player5213WinValueDAO = player5213AmountTextValueDAO * suitedThreeOfAKindPayoutReturnDAO
        player5213AmountTextDAO:SetText("21+3 Side Bet: " .. player5213WinValueDAO .. " G")
        player5213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player5213BetLabelDAO:SetText(player5213WinValueDAO .. " G")
    end

    player5213ProfitValueDAO = player5213WinValueDAO - player5213AmountTextValueDAO

    player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5213ProfitValueDAO)
    bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5213ProfitValueDAO)
    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

    if player5BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5213WinValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

    player5213WinDAO()
end

function player5StraightFlushWinDAO(messageDAO)
    player5213SideBetWinDAO = true
    player5213AmountTextValueDAO = tonumber(string.match(player5213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player5213AmountTextValueDAO then
        player5213WinValueDAO = player5213AmountTextValueDAO * straightFlushPayoutReturnDAO
        player5213AmountTextDAO:SetText("21+3 Side Bet: " .. player5213WinValueDAO .. " G")
        player5213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player5213BetLabelDAO:SetText(player5213WinValueDAO .. " G")
    end

    player5213ProfitValueDAO = player5213WinValueDAO - player5213AmountTextValueDAO

    player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5213ProfitValueDAO)
    bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5213ProfitValueDAO)
    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

    if player5BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5213WinValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

    player5213WinDAO()
end

function player5ThreeOfAKindWinDAO(messageDAO)
    player5213SideBetWinDAO = true
    player5213AmountTextValueDAO = tonumber(string.match(player5213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player5213AmountTextValueDAO then
        player5213WinValueDAO = player5213AmountTextValueDAO * threeOfAKindPayoutReturnDAO
        player5213AmountTextDAO:SetText("21+3 Side Bet: " .. player5213WinValueDAO .. " G")
        player5213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player5213BetLabelDAO:SetText(player5213WinValueDAO .. " G")
    end

    player5213ProfitValueDAO = player5213WinValueDAO - player5213AmountTextValueDAO

    player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5213ProfitValueDAO)
    bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5213ProfitValueDAO)
    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

    if player5BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5213WinValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

    player5213WinDAO()
end

function player5StraightWinDAO(messageDAO)
    player5213SideBetWinDAO = true
    player5213AmountTextValueDAO = tonumber(string.match(player5213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player5213AmountTextValueDAO then
        player5213WinValueDAO = player5213AmountTextValueDAO * straightPayoutReturnDAO
        player5213AmountTextDAO:SetText("21+3 Side Bet: " .. player5213WinValueDAO .. " G")
        player5213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player5213BetLabelDAO:SetText(player5213WinValueDAO .. " G")
    end

    player5213ProfitValueDAO = player5213WinValueDAO - player5213AmountTextValueDAO

    player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5213ProfitValueDAO)
    bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5213ProfitValueDAO)
    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

    if player5BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5213WinValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")

    player5213WinDAO()
end

function player5FlushWinDAO(messageDAO)
    player5213SideBetWinDAO = true
    player5213AmountTextValueDAO = tonumber(string.match(player5213AmountTextDAO:GetText(), ":(%s*%d+)%s*G$"))
    if player5213AmountTextValueDAO then
        player5213WinValueDAO = player5213AmountTextValueDAO * flushPayoutReturnDAO
        player5213AmountTextDAO:SetText("21+3 Side Bet: " .. player5213WinValueDAO .. " G")
        player5213AmountTextDAO:SetTextColor(0, 1, 0)
        dealerFrameDAO.player5213BetLabelDAO:SetText(player5213WinValueDAO .. " G")
    end

    player5213ProfitValueDAO = player5213WinValueDAO - player5213AmountTextValueDAO

    player5BankingTotalWonDAO = player5BankingTotalWonDAO + tonumber(player5213ProfitValueDAO)
    bankingFrameDAO.player5totalWonAmountDAO:SetText(player5BankingTotalWonDAO .. " G")

    player5BankingTotalProfitDAO = player5BankingTotalProfitDAO + tonumber(player5213ProfitValueDAO)
    bankingFrameDAO.player5totalProfitAmountDAO:SetText(player5BankingTotalProfitDAO .. " G")

    if player5BankingTotalProfitDAO >= 0 then
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.098, 0.878, 0.098)
    else
        bankingFrameDAO.player5totalProfitAmountDAO:SetTextColor(0.961, 0.306, 0.306)
    end
    
    player5BankingBankrollDAO = player5BankingBankrollDAO + tonumber(player5213WinValueDAO)
    bankingFrameDAO.player5BankrollAmountDAO:SetText(player5BankingBankrollDAO .. " G")
    
    player5213WinDAO()
end














-- >> INSURANCE TRIGGER <<
-- >> INSURANCE TRIGGER <<
-- >> INSURANCE TRIGGER <<

local function InsuranceTriggerDAO()
    SendChatMessage("{diamond} Insurance is available.", "RAID")
end









-- >> TIMERS <<
-- >> TIMERS <<
-- >> TIMERS <<

-- Text for timer when "Place Bets" buttonDAO is clicked
dealerFrameDAO.timerTextBetsDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
dealerFrameDAO.timerTextBetsDAO:SetPoint("CENTER", dealerFrameDAO, "CENTER", 12, -150)
dealerFrameDAO.timerTextBetsDAO:SetJustifyH("CENTER")
dealerFrameDAO.timerTextBetsDAO:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")

local function UpdateTimerDisplayBetsDAO(secondsRemainingDAO)
    dealerFrameDAO.timerTextBetsDAO:SetText("Place your bets!\nTimer: " .. secondsRemainingDAO .. " s remaining")
end
local function OnTimerUpdateBetsDAO()
    countdownDurationDAO = countdownDurationDAO - 1

    if countdownDurationDAO <= 0 then
        countdownTimerBetsDAO:Cancel()
        dealerFrameDAO.timerTextBetsDAO:SetText("No more bets!")
        dealerFrameDAO.timerTextBetsDAO:SetTextColor(1, 1, 0)
    else
        UpdateTimerDisplayBetsDAO(countdownDurationDAO)
    end
end
local function StartCountdownTimerBetsDAO()
    if countdownTimerBetsDAO then
        countdownTimerBetsDAO:Cancel()
    end
    countdownTimerBetsDAO = C_Timer.NewTicker(1, OnTimerUpdateBetsDAO, countdownDurationDAO)
    dealerFrameDAO.timerTextBetsDAO:Show()
    dealerFrameDAO.timerTextBetsDAO:SetTextColor(1, 1, 1)
end

-- Text for timer when "Hit" is said in chat
dealerFrameDAO.timerTextDAO = dealerFrameDAO:CreateFontString(nil, "OVERLAY", "GameFontHighlightLarge")
dealerFrameDAO.timerTextDAO:SetPoint("BOTTOMLEFT", dealerFrameDAO, 105, 65)
dealerFrameDAO.timerTextDAO:SetJustifyH("LEFT")
dealerFrameDAO.timerTextDAO:SetFont("Fonts\\FRIZQT__.TTF", 16, "OUTLINE")

local function UpdateTimerDisplayDAO(secondsRemainingDAO)
    dealerFrameDAO.timerTextDAO:SetText("Timer: " .. secondsRemainingDAO .. " s remaining")
end
local function OnTimerUpdateDAO()
    countdownDurationDAO = countdownDurationDAO - 1

    if countdownDurationDAO <= 0 then
        -- Time's up! Execute your codeDAO here when the timer hits 0
        dealerFrameDAO.timerTextDAO:SetText("Time is up!")
        dealerFrameDAO.timerTextDAO:SetTextColor(1, 0, 0)
    else
        UpdateTimerDisplayDAO(countdownDurationDAO)
    end
end
local function StartCountdownTimerDAO()
    if countdownTimerDAO then
        countdownTimerDAO:Cancel()
    end

    -- Ensure countdownDurationDAO is a valid number within the expected range
    local iterations = countdownDurationDAO or 0 -- Default to 0 if countdownDurationDAO is nil
    countdownTimerDAO = C_Timer.NewTicker(1, OnTimerUpdateDAO, iterations)

    dealerFrameDAO.timerTextDAO:Show()
    dealerFrameDAO.timerTextDAO:SetTextColor(1, 1, 1)
end
















-- >> RESET GAME STATE <<
-- >> RESET GAME STATE <<
-- >> RESET GAME STATE <<

local function ResetTimerDAO()
    -- Resetting "What is your decision?" and "Place your bets!" timers
    dealerFrameDAO.timerTextDAO:SetText("")
    dealerFrameDAO.timerTextDAO:Hide()

    dealerFrameDAO.timerTextBetsDAO:SetText("")
    dealerFrameDAO.timerTextBetsDAO:Hide()

    countdownDurationDAO = 30
end

local function RemoveCardImagesDAO()

    for iDAO = 1, #cardImagesDAO do
        cardImagesDAO[iDAO]:Hide()
    end

    cardImagesDAO = {}

    if player1NewCardImage1DAO then
        player1NewCardImage1DAO:Hide()
    end

    if player1NewCardImage2DAO then
        player1NewCardImage2DAO:Hide()
    end

    if player2NewCardImage1DAO then
        player2NewCardImage1DAO:Hide()
    end

    if player2NewCardImage2DAO then
        player2NewCardImage2DAO:Hide()
    end

    if player3NewCardImage1DAO then
        player3NewCardImage1DAO:Hide()
    end

    if player3NewCardImage2DAO then
        player3NewCardImage2DAO:Hide()
    end

    if player4NewCardImage1DAO then
        player4NewCardImage1DAO:Hide()
    end

    if player4NewCardImage2DAO then
        player4NewCardImage2DAO:Hide()
    end

    if player5NewCardImage1DAO then
        player5NewCardImage1DAO:Hide()
    end

    if player5NewCardImage2DAO then
        player5NewCardImage2DAO:Hide()
    end

end








local function ResultAnnouncement12345DAO()

    countdownResult12345DAO = countdownResult12345DAO - 1

    if countdownDurationResults12345DAO - countdownResult12345DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults12345DAO - countdownResult12345DAO == 3 then
        
        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults12345DAO - countdownResult12345DAO == 5 then

        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults12345DAO - countdownResult12345DAO == 7 then

        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults12345DAO - countdownResult12345DAO == 9 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement2345DAO()

    countdownResult2345DAO = countdownResult2345DAO - 1

    if countdownDurationResults2345DAO - countdownResult2345DAO == 1 then

        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults2345DAO - countdownResult2345DAO == 3 then
        
        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults2345DAO - countdownResult2345DAO == 5 then

        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults2345DAO - countdownResult2345DAO == 7 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement1345DAO()

    countdownResult1345DAO = countdownResult1345DAO - 1

    if countdownDurationResults1345DAO - countdownResult1345DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults1345DAO - countdownResult1345DAO == 3 then
        
        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults1345DAO - countdownResult1345DAO == 5 then

        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults1345DAO - countdownResult1345DAO == 7 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement1245DAO()

    countdownResult1245DAO = countdownResult1245DAO - 1

    if countdownDurationResults1245DAO - countdownResult1245DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults1245DAO - countdownResult1245DAO == 3 then
        
        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults1245DAO - countdownResult1245DAO == 5 then

        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults1245DAO - countdownResult1245DAO == 7 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement1235DAO()

    countdownResult1235DAO = countdownResult1235DAO - 1

    if countdownDurationResults1235DAO - countdownResult1235DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults1235DAO - countdownResult1235DAO == 3 then
        
        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults1235DAO - countdownResult1235DAO == 5 then

        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults1235DAO - countdownResult1235DAO == 7 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement1234DAO()

    countdownResult1234DAO = countdownResult1234DAO - 1

    if countdownDurationResults1234DAO - countdownResult1234DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults1234DAO - countdownResult1234DAO == 3 then
        
        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults1234DAO - countdownResult1234DAO == 5 then

        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults1234DAO - countdownResult1234DAO == 7 then

        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement345DAO()

    countdownResult345DAO = countdownResult345DAO - 1

    if countdownDurationResults345DAO - countdownResult345DAO == 1 then

        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults345DAO - countdownResult345DAO == 3 then
        
        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults345DAO - countdownResult345DAO == 5 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement245DAO()

    countdownResult245DAO = countdownResult245DAO - 1

    if countdownDurationResults245DAO - countdownResult245DAO == 1 then

        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults245DAO - countdownResult245DAO == 3 then
        
        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults245DAO - countdownResult245DAO == 5 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement235DAO()

    countdownResult235DAO = countdownResult235DAO - 1

    if countdownDurationResults235DAO - countdownResult235DAO == 1 then

        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults235DAO - countdownResult235DAO == 3 then
        
        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults235DAO - countdownResult235DAO == 5 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement234DAO()

    countdownResult234DAO = countdownResult234DAO - 1

    if countdownDurationResults234DAO - countdownResult234DAO == 1 then

        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults234DAO - countdownResult234DAO == 3 then
        
        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults234DAO - countdownResult234DAO == 5 then

        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement145DAO()

    countdownResult145DAO = countdownResult145DAO - 1

    if countdownDurationResults145DAO - countdownResult145DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults145DAO - countdownResult145DAO == 3 then
        
        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults145DAO - countdownResult145DAO == 5 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement135DAO()

    countdownResult135DAO = countdownResult135DAO - 1

    if countdownDurationResults135DAO - countdownResult135DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults135DAO - countdownResult135DAO == 3 then
        
        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults135DAO - countdownResult135DAO == 5 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement134DAO()

    countdownResult134DAO = countdownResult134DAO - 1

    if countdownDurationResults134DAO - countdownResult134DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults134DAO - countdownResult134DAO == 3 then
        
        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults134DAO - countdownResult134DAO == 5 then

        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement125DAO()

    countdownResult125DAO = countdownResult125DAO - 1

    if countdownDurationResults125DAO - countdownResult125DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults125DAO - countdownResult125DAO == 3 then
        
        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults125DAO - countdownResult125DAO == 5 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement124DAO()

    countdownResult124DAO = countdownResult124DAO - 1

    if countdownDurationResults124DAO - countdownResult124DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults124DAO - countdownResult124DAO == 3 then
        
        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults124DAO - countdownResult124DAO == 5 then

        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement123DAO()

    countdownResult123DAO = countdownResult123DAO - 1

    if countdownDurationResults123DAO - countdownResult123DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults123DAO - countdownResult123DAO == 3 then
        
        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end
    elseif countdownDurationResults123DAO - countdownResult123DAO == 5 then

        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement45DAO()

    countdownResult45DAO = countdownResult45DAO - 1

    if countdownDurationResults45DAO - countdownResult45DAO == 1 then

        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults45DAO - countdownResult45DAO == 3 then
        
        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement35DAO()

    countdownResult35DAO = countdownResult35DAO - 1

    if countdownDurationResults35DAO - countdownResult35DAO == 1 then

        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults35DAO - countdownResult35DAO == 3 then
        
        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement34DAO()

    countdownResult34DAO = countdownResult34DAO - 1

    if countdownDurationResults34DAO - countdownResult34DAO == 1 then

        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults34DAO - countdownResult34DAO == 3 then
        
        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement25DAO()

    countdownResult25DAO = countdownResult25DAO - 1

    if countdownDurationResults25DAO - countdownResult25DAO == 1 then

        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults25DAO - countdownResult25DAO == 3 then
        
        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement24DAO()

    countdownResult24DAO = countdownResult24DAO - 1

    if countdownDurationResults24DAO - countdownResult24DAO == 1 then

        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults24DAO - countdownResult24DAO == 3 then
        
        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement23DAO()

    countdownResult23DAO = countdownResult23DAO - 1

    if countdownDurationResults23DAO - countdownResult23DAO == 1 then

        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults23DAO - countdownResult23DAO == 3 then
        
        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement15DAO()

    countdownResult15DAO = countdownResult15DAO - 1

    if countdownDurationResults15DAO - countdownResult15DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults15DAO - countdownResult15DAO == 3 then
        
        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement14DAO()

    countdownResult14DAO = countdownResult14DAO - 1

    if countdownDurationResults14DAO - countdownResult14DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults14DAO - countdownResult14DAO == 3 then
        
        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement13DAO()

    countdownResult13DAO = countdownResult13DAO - 1

    if countdownDurationResults13DAO - countdownResult13DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults13DAO - countdownResult13DAO == 3 then
        
        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement12DAO()

    countdownResult12DAO = countdownResult12DAO - 1

    if countdownDurationResults12DAO - countdownResult12DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end

    elseif countdownDurationResults12DAO - countdownResult12DAO == 3 then
        
        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement5DAO()

    countdownResult5DAO = countdownResult5DAO - 1

    if countdownDurationResults5DAO - countdownResult5DAO == 1 then

        if player5ResultAnnouncedDAO == false then

            if player5SplitToggleDAO == true then

                if player5SplitResultAnnouncedDAO == false then

                    player5SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player5SplitH1CurrentBetTextDAO = player5Hand1BetAmountTextDAO:GetText()
                    player5SplitH1CurrentBetDAO = tonumber(string.match(player5SplitH1CurrentBetTextDAO, "%d+"))
                    player5SplitH2CurrentBetTextDAO = player5Hand2BetAmountTextDAO:GetText()
                    player5SplitH2CurrentBetDAO = tonumber(string.match(player5SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5SplitH2BJDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 20 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
                                
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 20 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 19 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 19 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player5SplitResultAnnouncedDAO = true
                        player5InsuranceLossDAO()
        
                        -- H1: Push
                        if player5SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player5SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName5DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[103]) -- "Player 5 - H1 Push, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName5DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[102]) -- "Player 5 - H1 Push, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName5DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[104]) -- "Player 5 - H1 Push, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH1CurrentTotalDAO >= 18 and player5SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName5DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[99]) -- "Player 5 - H1 Win, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName5DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[100]) -- "Player 5 - H1 Win, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player5SplitH2PushDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName5DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[101]) -- "Player 5 - H1 Win, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player5SplitH2LossDAO()
        
                                if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH1BJDAO()
                                else
                                    player5SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player5SplitH1CurrentTotalDAO >= 22 or player5SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player5SplitH2CurrentTotalDAO >= 18 and player5SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName5DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[105]) -- "Player 5 - H1 Loss, H2 Win"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player5SplitH2BJDAO()
                                else
                                    player5SplitH2WinDAO()
                                end
        
                                player5SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player5SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName5DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[106]) -- "Player 5 - H1 Loss, H2 Push"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player5SplitH2PushDAO()
                                player5SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player5SplitH2CurrentTotalDAO >= 22 or player5SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName5DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[107]) -- "Player 5 - H1 Loss, H2 Loss"
                                player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player5SplitH2LossDAO()
                                player5SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player5CurrentTotal = tonumber(string.match(dealerFrameDAO.player5CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player5CurrentBetText = player5MainBetAmountTextDAO:GetText()
                player5CurrentBet = tonumber(string.match(player5CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end

                    -- Loss
                    elseif player5CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player5BJWinDAO()

                    -- Push
                    elseif player5CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 20 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 19 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player5ResultAnnouncedDAO = true
                    player5InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or player5CurrentTotal >= 18 and player5CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName5DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[95]) -- "Player 5 - Win"
                        player5MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" then
                            player5BJWinDAO()
                        else
                            player5WinDAO()
                        end
                    
                    -- Push
                    elseif player5CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName5DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[96]) -- "Player 5 - Push"
                        player5MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player5PushDAO()

                    -- Loss
                    elseif player5CurrentTotal >= 22 or player5CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName5DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[97]) -- "Player 5 - Loss"
                        player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player5LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement4()

    countdownResult4DAO = countdownResult4DAO - 1

    if countdownDurationResults4DAO - countdownResult4DAO == 1 then

        if player4ResultAnnouncedDAO == false then

            if player4SplitToggleDAO == true then

                if player4SplitResultAnnouncedDAO == false then

                    player4SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player4SplitH1CurrentBetTextDAO = player4Hand1BetAmountTextDAO:GetText()
                    player4SplitH1CurrentBetDAO = tonumber(string.match(player4SplitH1CurrentBetTextDAO, "%d+"))
                    player4SplitH2CurrentBetTextDAO = player4Hand2BetAmountTextDAO:GetText()
                    player4SplitH2CurrentBetDAO = tonumber(string.match(player4SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4SplitH2BJDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 20 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
                                
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 20 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 19 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 19 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player4SplitResultAnnouncedDAO = true
                        player4InsuranceLossDAO()
        
                        -- H1: Push
                        if player4SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player4SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName4DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[89]) -- "Player 4 - H1 Push, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName4DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[88]) -- "Player 4 - H1 Push, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName4DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[90]) -- "Player 4 - H1 Push, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH1CurrentTotalDAO >= 18 and player4SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName4DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[85]) -- "Player 4 - H1 Win, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName4DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[86]) -- "Player 4 - H1 Win, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player4SplitH2PushDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName4DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[87]) -- "Player 4 - H1 Win, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player4SplitH2LossDAO()
        
                                if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH1BJDAO()
                                else
                                    player4SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player4SplitH1CurrentTotalDAO >= 22 or player4SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player4SplitH2CurrentTotalDAO >= 18 and player4SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName4DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[91]) -- "Player 4 - H1 Loss, H2 Win"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player4SplitH2BJDAO()
                                else
                                    player4SplitH2WinDAO()
                                end
        
                                player4SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player4SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName4DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[92]) -- "Player 4 - H1 Loss, H2 Push"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player4SplitH2PushDAO()
                                player4SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player4SplitH2CurrentTotalDAO >= 22 or player4SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName4DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[93]) -- "Player 4 - H1 Loss, H2 Loss"
                                player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player4SplitH2LossDAO()
                                player4SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player4CurrentTotal = tonumber(string.match(dealerFrameDAO.player4CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player4CurrentBetText = player4MainBetAmountTextDAO:GetText()
                player4CurrentBet = tonumber(string.match(player4CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end

                    -- Loss
                    elseif player4CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player4BJWinDAO()

                    -- Push
                    elseif player4CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 20 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 19 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player4ResultAnnouncedDAO = true
                    player4InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or player4CurrentTotal >= 18 and player4CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName4DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[81]) -- "Player 4 - Win"
                        player4MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" then
                            player4BJWinDAO()
                        else
                            player4WinDAO()
                        end
                    
                    -- Push
                    elseif player4CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName4DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[82]) -- "Player 4 - Push"
                        player4MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player4PushDAO()

                    -- Loss
                    elseif player4CurrentTotal >= 22 or player4CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName4DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[83]) -- "Player 4 - Loss"
                        player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player4LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement3()

    countdownResult3DAO = countdownResult3DAO - 1

    if countdownDurationResults3DAO - countdownResult3DAO == 1 then

        if player3ResultAnnouncedDAO == false then

            if player3SplitToggleDAO == true then

                if player3SplitResultAnnouncedDAO == false then

                    player3SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player3SplitH1CurrentBetTextDAO = player3Hand1BetAmountTextDAO:GetText()
                    player3SplitH1CurrentBetDAO = tonumber(string.match(player3SplitH1CurrentBetTextDAO, "%d+"))
                    player3SplitH2CurrentBetTextDAO = player3Hand2BetAmountTextDAO:GetText()
                    player3SplitH2CurrentBetDAO = tonumber(string.match(player3SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3SplitH2BJDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 20 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
                                
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 20 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 19 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 19 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player3SplitResultAnnouncedDAO = true
                        player3InsuranceLossDAO()
        
                        -- H1: Push
                        if player3SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player3SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName3DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[75]) -- "Player 3 - H1 Push, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName3DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[74]) -- "Player 3 - H1 Push, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName3DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[76]) -- "Player 3 - H1 Push, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH1CurrentTotalDAO >= 18 and player3SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName3DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[71]) -- "Player 3 - H1 Win, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName3DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[72]) -- "Player 3 - H1 Win, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player3SplitH2PushDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName3DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[73]) -- "Player 3 - H1 Win, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player3SplitH2LossDAO()
        
                                if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH1BJDAO()
                                else
                                    player3SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player3SplitH1CurrentTotalDAO >= 22 or player3SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player3SplitH2CurrentTotalDAO >= 18 and player3SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName3DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[77]) -- "Player 3 - H1 Loss, H2 Win"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player3SplitH2BJDAO()
                                else
                                    player3SplitH2WinDAO()
                                end
        
                                player3SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player3SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName3DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[78]) -- "Player 3 - H1 Loss, H2 Push"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player3SplitH2PushDAO()
                                player3SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player3SplitH2CurrentTotalDAO >= 22 or player3SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName3DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[79]) -- "Player 3 - H1 Loss, H2 Loss"
                                player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player3SplitH2LossDAO()
                                player3SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player3CurrentTotal = tonumber(string.match(dealerFrameDAO.player3CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player3CurrentBetText = player3MainBetAmountTextDAO:GetText()
                player3CurrentBet = tonumber(string.match(player3CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end

                    -- Loss
                    elseif player3CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player3BJWinDAO()

                    -- Push
                    elseif player3CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 20 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 19 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player3ResultAnnouncedDAO = true
                    player3InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or player3CurrentTotal >= 18 and player3CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName3DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[67]) -- "Player 3 - Win"
                        player3MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" then
                            player3BJWinDAO()
                        else
                            player3WinDAO()
                        end
                    
                    -- Push
                    elseif player3CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName3DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[68]) -- "Player 3 - Push"
                        player3MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player3PushDAO()

                    -- Loss
                    elseif player3CurrentTotal >= 22 or player3CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName3DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[69]) -- "Player 3 - Loss"
                        player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player3LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement2()

    countdownResult2DAO = countdownResult2DAO - 1

    if countdownDurationResults2DAO - countdownResult2DAO == 1 then

        if player2ResultAnnouncedDAO == false then

            if player2SplitToggleDAO == true then

                if player2SplitResultAnnouncedDAO == false then

                    player2SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player2SplitH1CurrentBetTextDAO = player2Hand1BetAmountTextDAO:GetText()
                    player2SplitH1CurrentBetDAO = tonumber(string.match(player2SplitH1CurrentBetTextDAO, "%d+"))
                    player2SplitH2CurrentBetTextDAO = player2Hand2BetAmountTextDAO:GetText()
                    player2SplitH2CurrentBetDAO = tonumber(string.match(player2SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2SplitH2BJDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 20 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
                                
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 20 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 19 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 19 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player2SplitResultAnnouncedDAO = true
                        player2InsuranceLossDAO()
        
                        -- H1: Push
                        if player2SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player2SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName2DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[61]) -- "Player 2 - H1 Push, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName2DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[60]) -- "Player 2 - H1 Push, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName2DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[62]) -- "Player 2 - H1 Push, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH1CurrentTotalDAO >= 18 and player2SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName2DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[57]) -- "Player 2 - H1 Win, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName2DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[58]) -- "Player 2 - H1 Win, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player2SplitH2PushDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName2DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[59]) -- "Player 2 - H1 Win, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player2SplitH2LossDAO()
        
                                if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH1BJDAO()
                                else
                                    player2SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player2SplitH1CurrentTotalDAO >= 22 or player2SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player2SplitH2CurrentTotalDAO >= 18 and player2SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName2DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[63]) -- "Player 2 - H1 Loss, H2 Win"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player2SplitH2BJDAO()
                                else
                                    player2SplitH2WinDAO()
                                end
        
                                player2SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player2SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName2DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[64]) -- "Player 2 - H1 Loss, H2 Push"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player2SplitH2PushDAO()
                                player2SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player2SplitH2CurrentTotalDAO >= 22 or player2SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName2DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[65]) -- "Player 2 - H1 Loss, H2 Loss"
                                player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player2SplitH2LossDAO()
                                player2SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player2CurrentTotal = tonumber(string.match(dealerFrameDAO.player2CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player2CurrentBetText = player2MainBetAmountTextDAO:GetText()
                player2CurrentBet = tonumber(string.match(player2CurrentBetText, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 21 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end

                    -- Loss
                    elseif player2CurrentTotal >= 22 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player2BJWinDAO()

                    -- Push
                    elseif player2CurrentTotal == 21 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 20 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal == 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 20 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 19 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 20 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 19 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 18 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 19 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 18 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 17 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player2ResultAnnouncedDAO = true
                    player2InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or player2CurrentTotal >= 18 and player2CurrentTotal <= 21 then
                        SendChatMessage("{star} " .. unitName2DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[53]) -- "Player 2 - Win"
                        player2MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" then
                            player2BJWinDAO()
                        else
                            player2WinDAO()
                        end
                    
                    -- Push
                    elseif player2CurrentTotal == 17 then
                        SendChatMessage("{square} " .. unitName2DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[54]) -- "Player 2 - Push"
                        player2MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player2PushDAO()

                    -- Loss
                    elseif player2CurrentTotal >= 22 or player2CurrentTotal <= 16 then
                        SendChatMessage("{cross} " .. unitName2DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[55]) -- "Player 2 - Loss"
                        player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player2LossDAO()

                    end
                end
            end
        end
    end
end
local function ResultAnnouncement1()

    countdownResult1DAO = countdownResult1DAO - 1

    if countdownDurationResults1DAO - countdownResult1DAO == 1 then

        if player1ResultAnnouncedDAO == false then

            if player1SplitToggleDAO == true then

                if player1SplitResultAnnouncedDAO == false then

                    player1SplitH1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH2CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText(), "%d+"))
                    dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                    player1SplitH1CurrentBetTextDAO = player1Hand1BetAmountTextDAO:GetText()
                    player1SplitH1CurrentBetDAO = tonumber(string.match(player1SplitH1CurrentBetTextDAO, "%d+"))
                    player1SplitH2CurrentBetTextDAO = player1Hand2BetAmountTextDAO:GetText()
                    player1SplitH2CurrentBetDAO = tonumber(string.match(player1SplitH2CurrentBetTextDAO, "%d+"))
        
                    -- Dealer: Blackjack
                    if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceWinDAO()
                        
                        -- H1: Push
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Push / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Loss / H2: Push
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: Bust
                    elseif dealerCurrentTotalDAO >= 22 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Win
                        if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
        
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
        
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 21
                    elseif dealerCurrentTotalDAO == 21 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 21 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1BJDAO()
                                
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1BJDAO()
                                
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 20 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1SplitH2BJDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 20 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
        
                            end
        
                        end
        
                    -- Dealer: 20
                    elseif dealerCurrentTotalDAO == 20 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 20 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 20 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                                
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
        
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO == 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO == 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 19 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 20 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 19 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 19
                    elseif dealerCurrentTotalDAO == 19 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 19 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 19 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 20 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
                                
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 18 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 20 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 19 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 18 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()                       
        
                            end
        
                        end
        
                    -- Dealer: 18
                    elseif dealerCurrentTotalDAO == 18 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 18 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 18 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 19 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 17 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 19 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 18 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 17 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
        
                    -- Dealer: 17
                    elseif dealerCurrentTotalDAO == 17 then
        
                        player1SplitResultAnnouncedDAO = true
                        player1InsuranceLossDAO()
        
                        -- H1: Push
                        if player1SplitH1CurrentTotalDAO == 17 then
        
                            -- H1: Push / H2: Push
                            if player1SplitH2CurrentTotalDAO == 17 then
                                
                                SendChatMessage("{square}{square} " .. unitName1DAO .. " pushes on both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[47]) -- "Player 1 - H1 Push, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1PushDAO()
                                
                            -- H1: Push / H2: Win
                            elseif dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{square}{star} " .. unitName1DAO .. " pushes on Hand 1 and has won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[46]) -- "Player 1 - H1 Push, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1PushDAO()
        
                            -- H1: Push / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{square}{cross} " .. unitName1DAO .. " pushes on Hand 1 and has lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[48]) -- "Player 1 - H1 Push, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1PushDAO()
                                
                            end
        
                        -- H1: Win
                        elseif dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH1CurrentTotalDAO >= 18 and player1SplitH1CurrentTotalDAO <= 21 then
        
                            -- H1: Win / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{star}{star} " .. unitName1DAO .. " has won both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[43]) -- "Player 1 - H1 Win, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{star}{square} " .. unitName1DAO .. " has won Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[44]) -- "Player 1 - H1 Win, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                
                                player1SplitH2PushDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            -- H1: Win / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{star}{cross} " .. unitName1DAO .. " has won Hand 1 and lost Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[45]) -- "Player 1 - H1 Win, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(0, 1, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                
                                player1SplitH2LossDAO()
        
                                if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH1BJDAO()
                                else
                                    player1SplitH1WinDAO()
                                end
        
                            end
        
                        -- H1: Loss
                        elseif player1SplitH1CurrentTotalDAO >= 22 or player1SplitH1CurrentTotalDAO <= 16 then
        
                            -- H1: Loss / H2: Win
                            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or player1SplitH2CurrentTotalDAO >= 18 and player1SplitH2CurrentTotalDAO <= 21 then
        
                                SendChatMessage("{cross}{star} " .. unitName1DAO .. " has lost Hand 1 and won Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[49]) -- "Player 1 - H1 Loss, H2 Win"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0, 1, 0)
                                
                                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                                    player1SplitH2BJDAO()
                                else
                                    player1SplitH2WinDAO()
                                end
        
                                player1SplitH1LossDAO()
        
                            -- H1: Loss / H2: Push
                            elseif player1SplitH2CurrentTotalDAO == 17 then
        
                                SendChatMessage("{cross}{square} " .. unitName1DAO .. " has lost Hand 1 and pushes on Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[50]) -- "Player 1 - H1 Loss, H2 Push"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                                player1SplitH2PushDAO()
                                player1SplitH1LossDAO()
                                
                            -- H1: Loss / H2: Loss
                            elseif player1SplitH2CurrentTotalDAO >= 22 or player1SplitH2CurrentTotalDAO <= 16 then
        
                                SendChatMessage("{cross}{cross} " .. unitName1DAO .. " has lost both Hand 1 and Hand 2.", "RAID")
                                PlaySoundFile(soundFilePathsDAO[51]) -- "Player 1 - H1 Loss, H2 Loss"
                                player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                                player1SplitH2LossDAO()
                                player1SplitH1LossDAO()
                                
                            end
        
                        end
                    end
                end
            else

                player1CurrentTotalDAO = tonumber(string.match(dealerFrameDAO.player1CardTotalTextDAO:GetText(), "%d+"))
                dealerCurrentTotalDAO = tonumber(string.match(dealerFrameDAO.dealerCardTotalTextDAO:GetText(), "%d+"))
                player1CurrentBetTextDAO = player1MainBetAmountTextDAO:GetText()
                player1CurrentBetDAO = tonumber(string.match(player1CurrentBetTextDAO, "%d+"))

                -- Dealer: Blackjack
                if dealerFrameDAO.dealerCardTotalTextDAO:GetText() == "Blackjack" then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceWinDAO()

                    -- Push
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                
                -- Dealer: Bust
                elseif dealerCurrentTotalDAO >= 22 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)

                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 21
                elseif dealerCurrentTotalDAO == 21 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        player1BJWinDAO()

                    -- Push
                    elseif player1CurrentTotalDAO == 21 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 20 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 20
                elseif dealerCurrentTotalDAO == 20 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO == 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 20 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 19 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 19
                elseif dealerCurrentTotalDAO == 19 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 20 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 19 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 18 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 18
                elseif dealerCurrentTotalDAO == 18 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 19 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 18 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 17 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end

                -- Dealer: 17
                elseif dealerCurrentTotalDAO == 17 then

                    player1ResultAnnouncedDAO = true
                    player1InsuranceLossDAO()

                    -- Win
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or player1CurrentTotalDAO >= 18 and player1CurrentTotalDAO <= 21 then
                        SendChatMessage("{star} " .. unitName1DAO .. " has won this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[39]) -- "Player 1 - Win"
                        player1MainBetAmountTextDAO:SetTextColor(0, 1, 0)
                        
                        if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" then
                            player1BJWinDAO()
                        else
                            player1WinDAO()
                        end
                    
                    -- Push
                    elseif player1CurrentTotalDAO == 17 then
                        SendChatMessage("{square} " .. unitName1DAO .. " has pushed this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[40]) -- "Player 1 - Push"
                        player1MainBetAmountTextDAO:SetTextColor(0.2, 0.7, 1)
                        player1PushDAO()

                    -- Loss
                    elseif player1CurrentTotalDAO >= 22 or player1CurrentTotalDAO <= 16 then
                        SendChatMessage("{cross} " .. unitName1DAO .. " has lost this round.", "RAID")
                        PlaySoundFile(soundFilePathsDAO[41]) -- "Player 1 - Loss"
                        player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                        player1LossDAO()

                    end
                end
            end
        end
    end
end








function StartResultsTimer12345DAO()
    if resultsTimer12345DAO then
        resultsTimer12345DAO:Cancel()
    end
    
    countdownResult12345DAO = countdownDurationResults12345DAO
    resultsTimer12345DAO = C_Timer.NewTicker(1, ResultAnnouncement12345DAO, countdownDurationResults12345DAO)

end
function StartResultsTimer2345DAO()
    if resultsTimer2345DAO then
        resultsTimer2345DAO:Cancel()
    end
    
    countdownResult2345DAO = countdownDurationResults2345DAO
    resultsTimer2345DAO = C_Timer.NewTicker(1, ResultAnnouncement2345DAO, countdownDurationResults2345DAO)

end
function StartResultsTimer1345DAO()
    if resultsTimer1345DAO then
        resultsTimer1345DAO:Cancel()
    end
    
    countdownResult1345DAO = countdownDurationResults1345DAO
    resultsTimer1345DAO = C_Timer.NewTicker(1, ResultAnnouncement1345DAO, countdownDurationResults1345DAO)

end
function StartResultsTimer1245DAO()
    if resultsTimer1245DAO then
        resultsTimer1245DAO:Cancel()
    end
    
    countdownResult1245DAO = countdownDurationResults1245DAO
    resultsTimer1245DAO = C_Timer.NewTicker(1, ResultAnnouncement1245DAO, countdownDurationResults1245DAO)

end
function StartResultsTimer1235DAO()
    if resultsTimer1235DAO then
        resultsTimer1235DAO:Cancel()
    end
    
    countdownResult1235DAO = countdownDurationResults1235DAO
    resultsTimer1235DAO = C_Timer.NewTicker(1, ResultAnnouncement1235DAO, countdownDurationResults1235DAO)

end
function StartResultsTimer1234DAO()
    if resultsTimer1234DAO then
        resultsTimer1234DAO:Cancel()
    end
    
    countdownResult1234DAO = countdownDurationResults1234DAO
    resultsTimer1234DAO = C_Timer.NewTicker(1, ResultAnnouncement1234DAO, countdownDurationResults1234DAO)

end
function StartResultsTimer345DAO()
    if resultsTimer345DAO then
        resultsTimer345DAO:Cancel()
    end
    
    countdownResult345DAO = countdownDurationResults345DAO
    resultsTimer345DAO = C_Timer.NewTicker(1, ResultAnnouncement345DAO, countdownDurationResults345DAO)

end
function StartResultsTimer245DAO()
    if resultsTimer245DAO then
        resultsTimer245DAO:Cancel()
    end
    
    countdownResult245DAO = countdownDurationResults245DAO
    resultsTimer245DAO = C_Timer.NewTicker(1, ResultAnnouncement245DAO, countdownDurationResults245DAO)

end
function StartResultsTimer235DAO()
    if resultsTimer235DAO then
        resultsTimer235DAO:Cancel()
    end
    
    countdownResult235DAO = countdownDurationResults235DAO
    resultsTimer235DAO = C_Timer.NewTicker(1, ResultAnnouncement235DAO, countdownDurationResults235DAO)

end
function StartResultsTimer234DAO()
    if resultsTimer234DAO then
        resultsTimer234DAO:Cancel()
    end
    
    countdownResult234DAO = countdownDurationResults234DAO
    resultsTimer234DAO = C_Timer.NewTicker(1, ResultAnnouncement234DAO, countdownDurationResults234DAO)

end
function StartResultsTimer145DAO()
    if resultsTimer145DAO then
        resultsTimer145DAO:Cancel()
    end
    
    countdownResult145DAO = countdownDurationResults145DAO
    resultsTimer145DAO = C_Timer.NewTicker(1, ResultAnnouncement145DAO, countdownDurationResults145DAO)

end
function StartResultsTimer135DAO()
    if resultsTimer135DAO then
        resultsTimer135DAO:Cancel()
    end
    
    countdownResult135DAO = countdownDurationResults135DAO
    resultsTimer135DAO = C_Timer.NewTicker(1, ResultAnnouncement135DAO, countdownDurationResults135DAO)

end
function StartResultsTimer134DAO()
    if resultsTimer134DAO then
        resultsTimer134DAO:Cancel()
    end
    
    countdownResult134DAO = countdownDurationResults134DAO
    resultsTimer134DAO = C_Timer.NewTicker(1, ResultAnnouncement134DAO, countdownDurationResults134DAO)

end
function StartResultsTimer125DAO()
    if resultsTimer125DAO then
        resultsTimer125DAO:Cancel()
    end
    
    countdownResult125DAO = countdownDurationResults125DAO
    resultsTimer125DAO = C_Timer.NewTicker(1, ResultAnnouncement125DAO, countdownDurationResults125DAO)

end
function StartResultsTimer124DAO()
    if resultsTimer124DAO then
        resultsTimer124DAO:Cancel()
    end
    
    countdownResult124DAO = countdownDurationResults124DAO
    resultsTimer124DAO = C_Timer.NewTicker(1, ResultAnnouncement124DAO, countdownDurationResults124DAO)

end
function StartResultsTimer123DAO()
    if resultsTimer123DAO then
        resultsTimer123DAO:Cancel()
    end
    
    countdownResult123DAO = countdownDurationResults123DAO
    resultsTimer123DAO = C_Timer.NewTicker(1, ResultAnnouncement123DAO, countdownDurationResults123DAO)

end
function StartResultsTimer45DAO()
    if resultsTimer45DAO then
        resultsTimer45DAO:Cancel()
    end
    
    countdownResult45DAO = countdownDurationResults45DAO
    resultsTimer45DAO = C_Timer.NewTicker(1, ResultAnnouncement45DAO, countdownDurationResults45DAO)

end
function StartResultsTimer35DAO()
    if resultsTimer35DAO then
        resultsTimer35DAO:Cancel()
    end
    
    countdownResult35DAO = countdownDurationResults35DAO
    resultsTimer35DAO = C_Timer.NewTicker(1, ResultAnnouncement35DAO, countdownDurationResults35DAO)

end
function StartResultsTimer34DAO()
    if resultsTimer34DAO then
        resultsTimer34DAO:Cancel()
    end
    
    countdownResult34DAO = countdownDurationResults34DAO
    resultsTimer34DAO = C_Timer.NewTicker(1, ResultAnnouncement34DAO, countdownDurationResults34DAO)

end
function StartResultsTimer25DAO()
    if resultsTimer25DAO then
        resultsTimer25DAO:Cancel()
    end
    
    countdownResult25DAO = countdownDurationResults25DAO
    resultsTimer25DAO = C_Timer.NewTicker(1, ResultAnnouncement25DAO, countdownDurationResults25DAO)

end
function StartResultsTimer24DAO()
    if resultsTimer24DAO then
        resultsTimer24DAO:Cancel()
    end
    
    countdownResult24DAO = countdownDurationResults24DAO
    resultsTimer24DAO = C_Timer.NewTicker(1, ResultAnnouncement24DAO, countdownDurationResults24DAO)

end
function StartResultsTimer23DAO()
    if resultsTimer23DAO then
        resultsTimer23DAO:Cancel()
    end
    
    countdownResult23DAO = countdownDurationResults23DAO
    resultsTimer23DAO = C_Timer.NewTicker(1, ResultAnnouncement23DAO, countdownDurationResults23DAO)

end
function StartResultsTimer15DAO()
    if resultsTimer15DAO then
        resultsTimer15DAO:Cancel()
    end
    
    countdownResult15DAO = countdownDurationResults15DAO
    resultsTimer15DAO = C_Timer.NewTicker(1, ResultAnnouncement15DAO, countdownDurationResults15DAO)

end
function StartResultsTimer14DAO()
    if resultsTimer14DAO then
        resultsTimer14DAO:Cancel()
    end
    
    countdownResult14DAO = countdownDurationResults14DAO
    resultsTimer14DAO = C_Timer.NewTicker(1, ResultAnnouncement14DAO, countdownDurationResults14DAO)

end
function StartResultsTimer13DAO()
    if resultsTimer13DAO then
        resultsTimer13DAO:Cancel()
    end
    
    countdownResult13DAO = countdownDurationResults13DAO
    resultsTimer13DAO = C_Timer.NewTicker(1, ResultAnnouncement13DAO, countdownDurationResults13DAO)

end
function StartResultsTimer12DAO()
    if resultsTimer12DAO then
        resultsTimer12DAO:Cancel()
    end
    
    countdownResult12DAO = countdownDurationResults12DAO
    resultsTimer12DAO = C_Timer.NewTicker(1, ResultAnnouncement12DAO, countdownDurationResults12DAO)

end
function StartResultsTimer5DAO()
    if resultsTimer5DAO then
        resultsTimer5DAO:Cancel()
    end
    
    countdownResult5DAO = countdownDurationResults5DAO
    resultsTimer5DAO = C_Timer.NewTicker(1, ResultAnnouncement5DAO, countdownDurationResults5DAO)

end
function StartResultsTimer4DAO()
    if resultsTimer4DAO then
        resultsTimer4DAO:Cancel()
    end
    
    countdownResult4DAO = countdownDurationResults4DAO
    resultsTimer4DAO = C_Timer.NewTicker(1, ResultAnnouncement4, countdownDurationResults4DAO)

end
function StartResultsTimer3DAO()
    if resultsTimer3DAO then
        resultsTimer3DAO:Cancel()
    end
    
    countdownResult3DAO = countdownDurationResults3DAO
    resultsTimer3DAO = C_Timer.NewTicker(1, ResultAnnouncement3, countdownDurationResults3DAO)

end
function StartResultsTimer2DAO()
    if resultsTimer2DAO then
        resultsTimer2DAO:Cancel()
    end
    
    countdownResult2DAO = countdownDurationResults2DAO
    resultsTimer2DAO = C_Timer.NewTicker(1, ResultAnnouncement2, countdownDurationResults2DAO)

end
function StartResultsTimer1DAO()
    if resultsTimer1DAO then
        resultsTimer1DAO:Cancel()
    end
    
    countdownResult1DAO = countdownDurationResults1DAO
    resultsTimer1DAO = C_Timer.NewTicker(1, ResultAnnouncement1, countdownDurationResults1DAO)

end










function DisplayRandomCard12345DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 2, 3, 4, 5
    if player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 6 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 67 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 69 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 71 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 73 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 74 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 75 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 76 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 77 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 78 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 79 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 80 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 81 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 82 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 83 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 84 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 85 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 86 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 87 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 88 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 89 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 90 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end  
            elseif turnDAO == 91 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 92 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 93 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 94 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 95 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 96 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 97 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 98 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 99 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 100 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 101 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 102 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 103 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 104 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 105 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 106 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 107 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 108 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 109 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 110 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end 
            elseif turnDAO == 111 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 112 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 113 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 114 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 115 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 116 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 5 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
        elseif turnDAO == 6 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 7 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 8 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 9 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end
        
        elseif turnDAO == 10 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            else
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        else
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 50 -- Skip to Player 3: 3rd Card
                    end
                else
                    if player2RunningTotalDAO == 20 then
                        if player2SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                            player2SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 30 -- Skip to Player 2: 3rd Card
                end
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 11 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 17 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 18 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                                    else
                                        if player5RunningTotalDAO == 20 then
                                            if player5SplitOfferedDAO == false then
                                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                                player5SplitOfferedDAO = true
                                            end
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        else
                                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                                        end
                                    end
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 30 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 23 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 26 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 27 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 28 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 29 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 30 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 50 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 50 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 30 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 30 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 30 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 50 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 50 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 30 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 30 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 31 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 37 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 38 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 40 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 42 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 50 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 43 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 50 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 50 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                turnDAO = 43 -- Skip to Player 2: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 44 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 45 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 46 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 47 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 48 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 50 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 49 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 50 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 50 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 51 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 52 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 53 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 6 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 54 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 55 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 56 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 57 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 58 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 5 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 60 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 6 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 61 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 7 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 62 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 8 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 110 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 70 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 63 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 70 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                turnDAO = 63 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 64 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 65 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 66 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 67 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 68 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 70 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 69 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 70 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 70 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 71 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 72 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 73 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 74 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 75 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 76 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 77 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 78 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 79 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 80 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 81 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 82 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 110 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 90 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 83 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 90 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                turnDAO = 83 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 84 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 85 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 86 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 87 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 88 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 90 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 89 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 110 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 90 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 110 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 90 -- Skip to Player 5: 3rd Card
                end
            end
        
        elseif turnDAO == 91 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 92 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 93 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 94 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 95 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 96 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 97 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 98 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 99 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 100 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 101 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 102 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 110 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 103 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 110 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 103 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 104 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 105 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 106 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 107 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 108 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 110 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 109 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 110 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 110 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 110 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 111 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 112 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 113 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 114 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 115 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 116 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard2345DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 2, 3, 4, 5
    if not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 5 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 67 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 69 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 73 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 74 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 75 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 76 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 77 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 78 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 79 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 80 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 81 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 82 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 83 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 84 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 85 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 86 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 87 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 88 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end  
            elseif turnDAO == 89 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 90 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 91 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 92 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 93 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 94 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
        elseif turnDAO == 5 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 7 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 8 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        else
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 3: 3rd Card
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 9 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 15 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 16 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 5 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 6 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 7 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 8 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 5 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 6 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 7 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 26 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 8 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 27 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 28 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 29 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 35 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 36 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 40 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 42 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 43 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 45 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 46 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 47 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 48 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 49 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 50 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 51 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 52 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 53 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 54 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 55 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 56 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 60 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 61 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 62 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 63 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 64 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 65 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 66 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 67 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 68 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 69 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 70 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 71 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 72 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 73 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 74 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 75 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 76 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 77 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 78 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 79 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 80 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 81 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 82 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 83 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 84 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 85 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 86 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 87 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 88 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 88 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 88 -- Skip to Dealer: 2nd Card
        
        elseif turnDAO == 89 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 90 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 91 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 92 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 93 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 94 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard1345DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 3, 4, 5
    if player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 5 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 67 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 69 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 73 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 74 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 75 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 76 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 77 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 78 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 79 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 80 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 81 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 82 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 83 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 84 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 85 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 86 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 87 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 88 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end  
            elseif turnDAO == 89 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 90 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 91 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 92 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 93 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 94 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
        elseif turnDAO == 5 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 7 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 8 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        else
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 3: 3rd Card
                end
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 9 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 15 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 16 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 26 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 27 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 28 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 29 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 35 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 36 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 40 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                turnDAO = 41 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 42 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 43 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 45 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 46 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 47 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 48 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 49 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 50 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 51 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 52 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 53 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 54 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 55 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 56 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 60 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 61 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 62 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 63 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 64 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 65 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 66 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 67 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 68 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 69 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 70 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 71 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 72 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 73 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 74 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 75 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 76 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 77 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 78 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 79 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 80 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 81 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 82 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 83 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 84 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 85 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 86 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 87 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 88 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 88 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 88 -- Skip to Dealer: 2nd Card
        
        elseif turnDAO == 89 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 90 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 91 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 92 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 93 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 94 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard1245DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 2, 4, 5
    if player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 5 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 67 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 69 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 73 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 74 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 75 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 76 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 77 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 78 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 79 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 80 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 81 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 82 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 83 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 84 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 85 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 86 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 87 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 88 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end  
            elseif turnDAO == 89 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 90 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 91 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 92 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 93 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 94 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
        elseif turnDAO == 5 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 7 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 8 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        else
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                else
                    if player2RunningTotalDAO == 20 then
                        if player2SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                            player2SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                end
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 9 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 15 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 16 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 26 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 27 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 28 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 29 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 35 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 36 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 40 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 42 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 43 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 45 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 46 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 47 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 48 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 49 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 50 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 51 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 52 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 53 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 54 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 55 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 56 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 60 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 61 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                turnDAO = 61 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 62 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 63 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 64 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 65 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 66 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 67 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 68 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 69 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 70 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 71 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 72 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 73 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 74 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 75 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 76 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 77 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 78 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 79 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 80 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 81 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 82 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 83 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 84 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 85 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 86 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 87 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 88 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 88 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 88 -- Skip to Dealer: 2nd Card
        
        elseif turnDAO == 89 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 90 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 91 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 92 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 93 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 94 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard1235DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 2, 3, 5
    if player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 5 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 67 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 69 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 73 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 74 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 75 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 76 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 77 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 78 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 79 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 80 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 81 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 82 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 83 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 84 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 85 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 86 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 87 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 88 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end  
            elseif turnDAO == 89 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 90 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 91 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 92 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 93 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 94 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
        elseif turnDAO == 5 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 7 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 8 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        else
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    end
                else
                    if player2RunningTotalDAO == 20 then
                        if player2SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                            player2SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                end
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 9 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 15 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 16 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player5RunningTotalDAO == 20 then
                                        if player5SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                            player5SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 26 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 27 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 28 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 29 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 35 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 36 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 40 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 42 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 43 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 45 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 46 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 47 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 48 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 49 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 50 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 51 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 6 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 52 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 53 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 54 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 55 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 56 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 5 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 6 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 7 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 60 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 8 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 61 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 62 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 63 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 64 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 65 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 66 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 67 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 68 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 69 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 70 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 71 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 72 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 73 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 74 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 75 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 76 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 77 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 78 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 79 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 80 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 81 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 81 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 82 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 83 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 84 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 85 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 86 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 87 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 88 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 88 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 88 -- Skip to Dealer: 2nd Card
        
        elseif turnDAO == 89 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 90 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 91 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 92 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 93 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 94 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard1234DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")

    -- Players: 1, 2, 3, 4
    if player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 5 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 67 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 69 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 73 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 74 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 75 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 76 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 77 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 78 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 79 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 80 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 81 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 82 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 83 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 84 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 85 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 86 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 87 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 88 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end  
            elseif turnDAO == 89 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 90 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 91 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 92 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 93 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 94 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
        elseif turnDAO == 5 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 7 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 8 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        else
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    end
                else
                    if player2RunningTotalDAO == 20 then
                        if player2SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                            player2SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                end
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 9 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 15 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 16 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                                else
                                    if player4RunningTotalDAO == 20 then
                                        if player4SplitOfferedDAO == false then
                                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                            player4SplitOfferedDAO = true
                                        end
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    else
                                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                                    end
                                end
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 28 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 21 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 26 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 27 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 28 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 28 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 28 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 29 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 35 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 36 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 40 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 88 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 48 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 48 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                turnDAO = 41 -- Skip to Player 2: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 42 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 43 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 45 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 46 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 48 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 47 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 48 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 48 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 49 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 50 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 51 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 6 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 52 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 53 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 54 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 55 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 56 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 5 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 6 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 7 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 60 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 8 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 88 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 68 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 61 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 68 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                turnDAO = 61 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 62 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 63 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 64 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 65 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 66 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 68 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 67 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 68 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 68 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 69 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 70 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 71 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 72 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 73 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 74 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 75 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 76 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 77 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 78 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 79 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 80 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 88 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 81 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 88 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 81 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 82 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 83 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 84 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 85 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 86 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 88 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 87 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 88 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 88 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 88 -- Skip to Dealer: 2nd Card
        
        elseif turnDAO == 89 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 90 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 91 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 92 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 93 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 94 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard345DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 3, 4, 5
    if not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 4 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 67 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 69 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
    
        elseif turnDAO == 4 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 5 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 7 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 13 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 14 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end           
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end           
            else
                if player3S1RunningTotalDAO >= 5 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end           
            else
                if player3S1RunningTotalDAO >= 6 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end           
            else
                if player3S1RunningTotalDAO >= 7 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end           
            else
                if player3S1RunningTotalDAO >= 8 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end           
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player3S2RunningTotalDAO >= 5 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player3S2RunningTotalDAO >= 6 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player3S2RunningTotalDAO >= 7 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player3S2RunningTotalDAO >= 8 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 26 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 27 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 28 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 29 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 33 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 34 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 40 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 42 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 43 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 45 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 46 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 47 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 48 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 49 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 50 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 51 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 65 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 66 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 67 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 68 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 69 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 70 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 71 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 72 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard245DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 2, 4, 5
    if not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 4 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 67 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 69 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
    
        elseif turnDAO == 4 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 5 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 7 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 13 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 14 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 5 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 6 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 7 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 8 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 5 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 6 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 7 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 8 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 26 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 27 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 28 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 29 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 33 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 34 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 40 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 42 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 43 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 45 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 46 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 47 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 48 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 49 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 50 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 51 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 65 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 66 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 67 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 68 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 69 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 70 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 71 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 72 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard235DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 2, 3, 5
    if not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 4 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 67 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 69 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
    
        elseif turnDAO == 4 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 5 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 7 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 13 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 14 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 5 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 6 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 7 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 8 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 5 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 6 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 7 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 8 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 26 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 27 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 28 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 29 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 33 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 34 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 40 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 42 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 43 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 45 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 46 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 47 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 48 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 49 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 50 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 51 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 65 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 66 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 67 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 68 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 69 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 70 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 71 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 72 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard234DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 2, 3, 4
    if not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 4 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 67 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 69 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
    
        elseif turnDAO == 4 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 5 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 7 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 13 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 14 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 5 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 6 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 7 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 8 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end           
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 5 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 6 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 7 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 8 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 26 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 27 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 28 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 29 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 33 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 34 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 40 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 42 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 43 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 45 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 46 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 47 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 48 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 49 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 50 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 51 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 52 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 53 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 54 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 55 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 56 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 60 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 61 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 62 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 63 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 64 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 65 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 66 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 67 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 68 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 69 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 70 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 71 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 72 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard145DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 4, 5
    if player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 4 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 67 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 69 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
    
        elseif turnDAO == 4 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 5 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                end
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 7 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 4: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 26 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 27 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 28 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 29 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 33 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 34 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                turnDAO = 39 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 40 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 42 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 43 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 45 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 46 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 47 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 48 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 49 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 50 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 51 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 65 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 66 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 67 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 68 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 69 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 70 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 71 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 72 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard135DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 3, 5
    if player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 4 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 67 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 69 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
    
        elseif turnDAO == 4 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 5 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 7 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 26 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 27 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 28 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 29 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 33 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 34 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 40 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 42 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 43 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 45 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 46 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 47 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 48 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 49 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 50 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 51 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 65 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 66 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 67 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 68 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 69 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 70 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 71 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 72 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard134DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 3, 4
    if player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 4 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 67 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 69 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
    
        elseif turnDAO == 4 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 5 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 7 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 3: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 26 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 27 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 28 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 29 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 33 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 34 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                turnDAO = 39 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 40 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 42 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 43 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 45 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 46 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 47 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 48 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 49 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 50 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 51 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 52 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 53 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 54 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 55 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 56 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 60 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 61 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 62 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 63 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 64 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 65 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 66 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 67 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 68 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 69 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 70 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 71 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 72 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard125DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")

    -- Players: 1, 2, 5
    if player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 4 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 67 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 69 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
    
        elseif turnDAO == 4 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 5 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    if player2RunningTotalDAO == 20 then
                        if player2SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                            player2SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                end
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 7 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player5RunningTotalDAO == 20 then
                                    if player5SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                        player5SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 26 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 27 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 28 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 29 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 33 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 34 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player5RunningTotalDAO == 20 then
                                if player5SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                    player5SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 5: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 5: 3rd Card
                    end
                end
            else
                turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 40 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 42 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 43 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 5: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 45 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 46 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 5: 3rd Card
                end
            end

        elseif turnDAO == 47 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 48 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 49 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 50 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 51 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 52 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 53 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 54 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 55 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 56 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 59 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 60 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 61 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 62 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 63 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 64 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 65 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 66 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 67 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 68 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 69 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 70 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 71 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 72 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard124DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 2, 4
    if player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 4 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 67 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 69 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
    
        elseif turnDAO == 4 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 5 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                else
                    if player2RunningTotalDAO == 20 then
                        if player2SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                            player2SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                end
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 7 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player4RunningTotalDAO == 20 then
                                    if player4SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                        player4SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 26 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 27 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 28 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 29 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 33 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 34 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player4RunningTotalDAO == 20 then
                                if player4SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                    player4SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 4: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 4: 3rd Card
                    end
                end
            else
                turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 40 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 42 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 43 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 4: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 45 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 46 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 4: 3rd Card
                end
            end

        elseif turnDAO == 47 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 48 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 49 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 50 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 51 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 52 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 53 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 54 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 55 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 56 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 59 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 60 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 61 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 62 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 63 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 64 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 65 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 66 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 67 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 68 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 69 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 70 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 71 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 72 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard123DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 2, 3
    if player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 4 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 51 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 52 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 53 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 54 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 55 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 56 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 57 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 58 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 59 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 60 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 61 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 62 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 63 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 64 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 65 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 66 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end    
            elseif turnDAO == 67 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 68 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 69 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 70 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 71 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 72 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
            
    
        elseif turnDAO == 4 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 5 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 6 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                else
                    if player2RunningTotalDAO == 20 then
                        if player2SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                            player2SplitOfferedDAO = true
                        end
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                end
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 7 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 13 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 14 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 18 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end           
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                                turnDAO = 66 -- Skip to Dealer: 2nd Card
                            else
                                if player3RunningTotalDAO == 20 then
                                    if player3SplitOfferedDAO == false then
                                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                        player3SplitOfferedDAO = true
                                    end
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                else
                                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                                end
                            end
                        else
                            if player2RunningTotalDAO == 20 then
                                if player2SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                    player2SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                                turnDAO = 26 -- Skip to Player 2: 3rd Card
                            end
                        end
                    else
                        turnDAO = 19 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 24 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 25 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                            turnDAO = 26 -- Skip to Player 2: 3rd Card
                        end
                    end
                end           
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 26 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 26 -- Skip to Player 2: 3rd Card
                end
            end

        elseif turnDAO == 27 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 28 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 29 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 30 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 31 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 32 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 33 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 34 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 38 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                            turnDAO = 66 -- Skip to Dealer: 2nd Card
                        else
                            if player3RunningTotalDAO == 20 then
                                if player3SplitOfferedDAO == false then
                                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                    player3SplitOfferedDAO = true
                                end
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            else
                                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                                turnDAO = 46 -- Skip to Player 3: 3rd Card
                            end
                        end
                    else
                        turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 39 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 3: 3rd Card
                    else
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 46 -- Skip to Player 3: 3rd Card
                    end
                end
            else
                turnDAO = 39 -- Skip to Player 2: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 40 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 41 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 42 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end 

        elseif turnDAO == 43 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 44 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        else
                            SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                            turnDAO = 46 -- Skip to Player 3: 3rd Card
                        end
                    end
                end
            end

        elseif turnDAO == 45 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 46 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                else
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 46 -- Skip to Player 3: 3rd Card
                end
            end

        elseif turnDAO == 47 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 48 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 49 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 6 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 50 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 51 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 52 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 53 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 54 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 55 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 5 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 56 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 6 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 57 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 7 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 58 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 8 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 66 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 59 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 66 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 59 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 60 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 61 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 62 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 63 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 64 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 66 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 65 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 66 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 66 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 67 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 68 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 69 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 70 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 71 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 72 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard45DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 4, 5
    if not player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 3 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 3 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                turnDAO = 24 -- Skip to Player 5: 3rd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 5 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 6 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 7 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 11 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 24 -- Skip to Player 5: 3rd Card
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                    end
                else
                    turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 12 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then
                if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            else
                turnDAO = 17 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 18 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player4S2RunningTotalDAO >= 5 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player4S2RunningTotalDAO >= 6 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player4S2RunningTotalDAO >= 7 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player4S2RunningTotalDAO >= 8 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 5: 3rd Card
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 24 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 5: 3rd Card
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 25 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 26 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 27 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 28 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 29 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 30 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 31 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 32 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 38 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 39 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 40 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 41 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 42 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 43 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 44 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 45 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 46 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 47 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 48 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 49 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 50 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard35DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 3, 5
    if not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 3 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 3 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                turnDAO = 24 -- Skip to Player 5: 3rd Card
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 5 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 6 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 7 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player3RunningTotalDAO >= 6 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 11 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 24 -- Skip to Player 5: 3rd Card
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                    end
                else
                    turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 12 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 5 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 6 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 7 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 8 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            else
                turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 18 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player3S2RunningTotalDAO >= 5 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player3S2RunningTotalDAO >= 6 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player3S2RunningTotalDAO >= 7 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player3S2RunningTotalDAO >= 8 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 5: 3rd Card
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 24 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 5: 3rd Card
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 25 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 26 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 27 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 28 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 29 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 30 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 31 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 32 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 38 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 39 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 40 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 41 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 42 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 43 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 44 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 45 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 46 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 47 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 48 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 49 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 50 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard34DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 3, 4
    if not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 3 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 3 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    end
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                turnDAO = 24 -- Skip to Player 4: 3rd Card
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 5 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 6 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 7 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player3RunningTotalDAO >= 6 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 11 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 24 -- Skip to Player 4: 3rd Card
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                    end
                else
                    turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 12 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 5 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 6 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 7 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 8 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then
                if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
            else
                turnDAO = 17 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 18 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player3S2RunningTotalDAO >= 5 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player3S2RunningTotalDAO >= 6 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player3S2RunningTotalDAO >= 7 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player3S2RunningTotalDAO >= 8 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 4: 3rd Card
                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 24 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 4: 3rd Card
                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 25 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 26 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 27 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 28 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 29 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 30 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 31 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 32 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 38 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 39 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 40 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 41 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 42 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 43 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 44 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 45 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 46 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 47 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 48 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 49 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 50 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard25DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 2, 5
    if not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 3 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 3 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                turnDAO = 24 -- Skip to Player 5: 3rd Card
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 5 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 6 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 7 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 6 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 11 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 24 -- Skip to Player 5: 3rd Card
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                    end
                else
                    turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 12 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 5 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 6 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 7 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 8 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            else
                turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 18 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 5 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 6 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 7 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 8 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 5: 3rd Card
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 24 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 5: 3rd Card
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 25 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 26 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 27 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 28 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 29 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 30 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 31 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 32 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 38 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 39 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 40 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 41 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 42 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 43 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 44 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 45 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 46 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 47 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 48 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 49 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 50 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard24DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 2, 4
    if not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 3 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 3 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    end
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                turnDAO = 24 -- Skip to Player 4: 3rd Card
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 5 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 6 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 7 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 6 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 11 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 24 -- Skip to Player 4: 3rd Card
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                    end
                else
                    turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 12 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 5 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 6 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 7 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 8 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
            else
                turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 18 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 5 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 6 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 7 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 8 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 4: 3rd Card
                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 24 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 4: 3rd Card
                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 25 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 26 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 27 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 28 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 29 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 30 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 31 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 32 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 38 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 39 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 40 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 41 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 42 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 43 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 44 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 45 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 46 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 47 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 48 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 49 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 50 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard23DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 2, 3
    if not player1ActiveDAO and player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 3 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 3 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    end
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                turnDAO = 24 -- Skip to Player 3: 3rd Card
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 5 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 6 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 7 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 6 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 11 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 24 -- Skip to Player 3: 3rd Card
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                    end
                else
                    turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 12 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 5 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 6 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 7 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 8 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then
                if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
            else
                turnDAO = 17 -- Skip to Player 2: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 18 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 5 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 6 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 7 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player2S2RunningTotalDAO >= 8 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 3: 3rd Card
                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 24 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 3: 3rd Card
                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 25 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 26 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 27 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 6 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 28 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 29 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 30 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 31 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 32 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 5 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 6 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 7 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 8 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 38 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 39 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 40 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 41 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 42 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 43 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 44 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 45 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 46 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 47 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 48 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 49 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 50 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard15DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 5
    if player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 3 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 3 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    end
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                turnDAO = 24 -- Skip to Player 5: 3rd Card
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 5 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 6 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 5 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 7 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 6 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 7 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 8 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 11 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 24 -- Skip to Player 5: 3rd Card
                    SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    if player5RunningTotalDAO == 20 then
                        if player5SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                            player5SplitOfferedDAO = true
                        end
                    end
                else
                    turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 12 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            else
                turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 18 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player5RunningTotalDAO == 20 then
                            if player5SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                                player5SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 5: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 5: 3rd Card
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 24 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player5RunningTotalDAO == 20 then
                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 5: 3rd Card
                SendChatMessage("What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 25 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 26 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 27 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 28 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 29 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 30 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 31 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                    print("Player 5 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end

        elseif turnDAO == 32 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 37 -- Skip to Player 5: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 38 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 39 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 40 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 41 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 42 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 43 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 44 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 45 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 46 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 47 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 48 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 49 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 50 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard14DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 4
    if player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 3 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 3 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    end
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                turnDAO = 24 -- Skip to Player 4: 3rd Card
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 5 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 6 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 5 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 7 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 6 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 7 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 8 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 11 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 24 -- Skip to Player 4: 3rd Card
                    SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    if player4RunningTotalDAO == 20 then
                        if player4SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                            player4SplitOfferedDAO = true
                        end
                    end
                else
                    turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 12 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
            else
                turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 18 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player4RunningTotalDAO == 20 then
                            if player4SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                                player4SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 4: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 4: 3rd Card
                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 24 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player4RunningTotalDAO == 20 then
                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 4: 3rd Card
                SendChatMessage("What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 25 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 26 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 27 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 28 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 29 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 30 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 31 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                    print("Player 4 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 32 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 37 -- Skip to Player 4: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 38 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 39 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 40 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 41 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 42 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 43 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 44 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 45 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 46 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 47 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 48 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 49 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 50 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard13DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 3
    if player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 3 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 3 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    end
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                turnDAO = 24 -- Skip to Player 3: 3rd Card
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 5 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 6 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 5 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 7 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 6 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 7 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 8 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 11 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 24 -- Skip to Player 3: 3rd Card
                    SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    if player3RunningTotalDAO == 20 then
                        if player3SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                            player3SplitOfferedDAO = true
                        end
                    end
                else
                    turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 12 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
            else
                turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 18 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player3RunningTotalDAO == 20 then
                            if player3SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                                player3SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 3: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 3: 3rd Card
                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 24 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player3RunningTotalDAO == 20 then
                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 3: 3rd Card
                SendChatMessage("What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 25 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 26 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 27 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 6 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 28 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 29 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 30 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 31 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                    print("Player 3 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 32 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 5 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 6 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 7 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            else
                if player3S1RunningTotalDAO >= 8 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 37 -- Skip to Player 3: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 38 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 39 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 40 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 41 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 42 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 43 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 44 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 45 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 46 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 47 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 48 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 49 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 50 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard12DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 1, 2
    if player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 2 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 3 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 29 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 30 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 31 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 32 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 33 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 34 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 35 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 36 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 37 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 38 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 39 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 40 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 41 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 42 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 43 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 44 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 45 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 46 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 47 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 48 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 49 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 50 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 1 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end
        
        elseif turnDAO == 2 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 3 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 running total: Blackjack")
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 4 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 running total: Blackjack")
                    if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    end
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

            if dealerFrameDAO.player1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1CardTotalTextDAO:GetText() == "21" then
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                turnDAO = 24 -- Skip to Player 2: 3rd Card
            else
                if player1RunningTotalDAO == 20 then
                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    end
                end
                SendChatMessage("What is your decision, " .. unitName1DAO .. "?", "RAID")
            end
        
        elseif turnDAO == 5 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 6 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 5 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 7 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 6 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 8 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 7 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 9 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player1RunningTotalDAO >= 8 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 10 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 11 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                    print("Player 1 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 24 -- Skip to Player 2: 3rd Card
                    SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    if player2RunningTotalDAO == 20 then
                        if player2SplitOfferedDAO == false then
                            SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                            player2SplitOfferedDAO = true
                        end
                    end
                else
                    turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 12 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 15 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 16 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    else
                        turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 17 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "21" then
                if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
            else
                turnDAO = 17 -- Skip to Player 1: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 18 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 19 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 20 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 21 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 22 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        if player2RunningTotalDAO == 20 then
                            if player2SplitOfferedDAO == false then
                                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                                player2SplitOfferedDAO = true
                            end
                        end
                        turnDAO = 24 -- Skip to Player 2: 3rd Card
                        SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 23 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 2: 3rd Card
                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 24 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2CardTotalTextDAO:GetText() == "21" then
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                if player2RunningTotalDAO == 20 then
                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    end
                end
                turnDAO = 24 -- Skip to Player 2: 3rd Card
                SendChatMessage("What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 25 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 26 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 27 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player2RunningTotalDAO >= 6 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 28 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 29 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 30 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H1) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 31 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                    print("Player 2 (H2) running total: Blackjack")
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "21" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 32 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 33 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 5 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 34 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 6 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 35 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 7 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 36 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            else
                if player2S1RunningTotalDAO >= 8 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                        turnDAO = 44 -- Skip to Dealer: 2nd Card
                    else
                        turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    end
                end
            end

        elseif turnDAO == 37 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" or dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "21" then 
                turnDAO = 44 -- Skip to Dealer: 2nd Card
            else
                turnDAO = 37 -- Skip to Player 2: 3rd Card (Split H2)
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end
            
        elseif turnDAO == 38 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 39 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 40 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end 

        elseif turnDAO == 41 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 42 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 44 -- Skip to Dealer: 2nd Card
                end
            end

        elseif turnDAO == 43 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            
            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 44 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

            turnDAO = 44 -- Skip to Dealer: 2nd Card

        elseif turnDAO == 45 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 46 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 47 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 48 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 49 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 50 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard5DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 5
    if not player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 5: 1st Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 2 then -- Player 5: 2nd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Player 5: 3rd Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 5: 4th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 5: 5th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 5: 6th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 5: 7th Card
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 5: 2nd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 5: 2nd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 5: 3rd Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 5: 4th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 5: 5th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 5: 6th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 5: 7th Card (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 5: Double (3rd Card) (Split H1)
                player5S1RunningTotalDAO = player5S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S1RunningTotalWithAceDAO = player5S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 5: 3rd Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 5: 4th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 5: 5th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 5: 6th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 5: 7th Card (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 5: Double (3rd Card) (Split H2)
                player5S2RunningTotalDAO = player5S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5S2RunningTotalWithAceDAO = player5S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 5: Double (3rd Card)
                player5RunningTotalDAO = player5RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName5DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player5RunningTotalWithAceDAO = player5RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 5: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -75)
            if player5RunningTotalDAO == 1 then
                print("Player 5 running total: " .. player5RunningTotalDAO .. " or " .. player5RunningTotalWithAceDAO)
            else
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end
        
        elseif turnDAO == 1 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 2 then -- Player 5: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -85)
            
            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5RunningTotalDAO == 2 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 12. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                        print("Player 5 running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage(unitName5DAO .. " has Blackjack.", "RAID")
                        print("Player 5 running total: Blackjack") 
                    end
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            elseif player5RunningTotalDAO == 20 then
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end
            else
                SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                print("Player 5 running total: " .. player5RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Player 5: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 13. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 4 then -- Player 5: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -105)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 14. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 5 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 5 then -- Player 5: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -115)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 15. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 6 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 6 then -- Player 5: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -125)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 16. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 7 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 7 then -- Player 5: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -135)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 17. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 18. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 19. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. " or 20. What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO .. " or 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 8 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ". What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 8 then -- Player 5: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -80)
            
            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                        print("Player 5 (H1) running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage("Hand 1: " .. unitName5DAO .. " has Blackjack.", "RAID")
                        print("Player 5 (H1) running total: Blackjack") 
                    end
                end
            else
                SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
            end

        elseif turnDAO == 9 then -- Player 5: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 220, -115)
            
            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "2 or 12"
                if player5S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 12")
                -- Player 5: "3 or 13"
                elseif player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                        print("Player 5 (H2) running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage("Hand 2: " .. unitName5DAO .. " has Blackjack.", "RAID")
                        print("Player 5 (H2) running total: Blackjack")  
                    end
                end
            else
                SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
            end

            if dealerFrameDAO.player5SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
            end 

        elseif turnDAO == 10 then -- Player 5: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 5: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -100)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                end
            else
                if player5S1RunningTotalDAO >= 5 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 5: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 160, -110)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                end
            else
                if player5S1RunningTotalDAO >= 6 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 5: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 150, -120)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                end
            else
                if player5S1RunningTotalDAO >= 7 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 5: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 140, -130)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 8 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                    
                end
            end
            
            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                turnDAO = 22 -- Skip to Dealer 2nd Card
            else
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
            end

        elseif turnDAO == 15 then -- Player 5: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -90)

            if player5S1RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H1) running total: 13")
                -- Player 5: "14"
                elseif player5S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H1) running total: 14")
                -- Player 5: "15" 
                elseif player5S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H1) running total: 15")
                -- Player 5: "16"
                elseif player5S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H1) running total: 16")
                -- Player 5: "17"
                elseif player5S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H1) running total: 17")
                -- Player 5: "18"
                elseif player5S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H1) running total: 18")
                -- Player 5: "19"
                elseif player5S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H1) running total: 19")
                -- Player 5: "20"
                elseif player5S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H1) running total: 20")
                -- Player 5: "21"
                elseif player5S1RunningTotalDAO == 11 or player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                elseif player5S1RunningTotalDAO >= 12 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S1RunningTotalDAO >= 4 and player5S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has " .. player5S1RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H1) running total: " .. player5S1RunningTotalDAO)
                elseif player5S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName5DAO .. " has gone bust with a total of " .. player5S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player5SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                turnDAO = 22 -- Skip to Dealer 2nd Card
            else
                SendChatMessage("(H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                turnDAO = 15 -- Skip to Player 5 3rd Card (Split H2)
            end

        elseif turnDAO == 16 then -- Player 5: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "3 or 13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 13")
                -- Player 5: "4 or 14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 17 then -- Player 5: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -135)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "4 or 14"
                if player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 14")
                -- Player 5: "5 or 15"
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 5 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 18 then -- Player 5: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 190, -145)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "5 or 15"
                if player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 15")
                -- Player 5: "6 or 16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 6 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 19 then -- Player 5: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 180, -155)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "6 or 16"
                if player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 16")
                -- Player 5: "7 or 17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player5S2RunningTotalDAO >= 7 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 20 then -- Player 5: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 170, -165)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "7 or 17"
                if player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 17")
                -- Player 5: "8 or 18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 18")
                -- Player 5: "9 or 19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 19")
                -- Player 5: "10 or 20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO .. " or 20")
                -- Player 5: "Blackjack"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 8 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName5DAO .. "?", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            turnDAO = 22 -- Skip to Dealer 2nd Card

        elseif turnDAO == 21 then -- Player 5: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 210, -125)

            if player5S2RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 (H2) running total: 13")
                -- Player 5: "14"
                elseif player5S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 (H2) running total: 14")
                -- Player 5: "15" 
                elseif player5S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 (H2) running total: 15")
                -- Player 5: "16"
                elseif player5S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 (H2) running total: 16")
                -- Player 5: "17"
                elseif player5S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 (H2) running total: 17")
                -- Player 5: "18"
                elseif player5S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 (H2) running total: 18")
                -- Player 5: "19"
                elseif player5S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 (H2) running total: 19")
                -- Player 5: "20"
                elseif player5S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 (H2) running total: 20")
                -- Player 5: "21"
                elseif player5S2RunningTotalDAO == 11 or player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                elseif player5S2RunningTotalDAO >= 12 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5S2RunningTotalDAO >= 4 and player5S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has " .. player5S2RunningTotalDAO .. ".", "RAID")
                    print("Player 5 (H2) running total: " .. player5S2RunningTotalDAO)
                elseif player5S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName5DAO .. " has gone bust with a total of " .. player5S2RunningTotalDAO .. ".", "RAID")
                end
            end
            turnDAO = 22 -- Skip to Dealer 2nd Card

        elseif turnDAO == 22 then -- Player 5: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 200, -95)

            if player5RunningTotalWithAceDAO >= 1 then

                -- Player 5: "13"
                if player5RunningTotalDAO == 3 then
                    SendChatMessage(unitName5DAO .. " has 13.", "RAID")
                    print("Player 5 running total: 13")
                -- Player 5: "14"
                elseif player5RunningTotalDAO == 4 then
                    SendChatMessage(unitName5DAO .. " has 14.", "RAID")
                    print("Player 5 running total: 14")
                -- Player 5: "15" 
                elseif player5RunningTotalDAO == 5 then
                    SendChatMessage(unitName5DAO .. " has 15.", "RAID")
                    print("Player 5 running total: 15")
                -- Player 5: "16"
                elseif player5RunningTotalDAO == 6 then
                    SendChatMessage(unitName5DAO .. " has 16.", "RAID")
                    print("Player 5 running total: 16")
                -- Player 5: "17"
                elseif player5RunningTotalDAO == 7 then
                    SendChatMessage(unitName5DAO .. " has 17.", "RAID")
                    print("Player 5 running total: 17")
                -- Player 5: "18"
                elseif player5RunningTotalDAO == 8 then
                    SendChatMessage(unitName5DAO .. " has 18.", "RAID")
                    print("Player 5 running total: 18")
                -- Player 5: "19"
                elseif player5RunningTotalDAO == 9 then
                    SendChatMessage(unitName5DAO .. " has 19.", "RAID")
                    print("Player 5 running total: 19")
                -- Player 5: "20"
                elseif player5RunningTotalDAO == 10 then
                    SendChatMessage(unitName5DAO .. " has 20.", "RAID")
                    print("Player 5 running total: 20")
                -- Player 5: "21"
                elseif player5RunningTotalDAO == 11 or player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                elseif player5RunningTotalDAO >= 12 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            else
                if player5RunningTotalDAO >= 4 and player5RunningTotalDAO <= 20 then
                    SendChatMessage(unitName5DAO .. " has " .. player5RunningTotalDAO .. ".", "RAID")
                    print("Player 5 running total: " .. player5RunningTotalDAO)
                elseif player5RunningTotalDAO == 21 then
                    SendChatMessage(unitName5DAO .. " has 21.", "RAID")
                    print("Player 5 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName5DAO .. " has gone bust with a total of " .. player5RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 23 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 24 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 25 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 26 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 27 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 28 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard4DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 4
    if not player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 4: 1st Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 2 then -- Player 4: 2nd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Player 4: 3rd Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 4: 4th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 4: 5th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 4: 6th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 4: 7th Card
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 4: 2nd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 4: 2nd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 4: 3rd Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 4: 4th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 4: 5th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 4: 6th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 4: 7th Card (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 4: Double (3rd Card) (Split H1)
                player4S1RunningTotalDAO = player4S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S1RunningTotalWithAceDAO = player4S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 4: 3rd Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 4: 4th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 4: 5th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 4: 6th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 4: 7th Card (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 4: Double (3rd Card) (Split H2)
                player4S2RunningTotalDAO = player4S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4S2RunningTotalWithAceDAO = player4S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 4: Double (3rd Card)
                player4RunningTotalDAO = player4RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName4DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player4RunningTotalWithAceDAO = player4RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 4: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 128, -5)
            if player4RunningTotalDAO == 1 then
                print("Player 4 running total: " .. player4RunningTotalDAO .. " or " .. player4RunningTotalWithAceDAO)
            else
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end
        
        elseif turnDAO == 1 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 2 then -- Player 4: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 118, -15)
            
            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4RunningTotalDAO == 2 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 12. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                        print("Player 4 running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage(unitName4DAO .. " has Blackjack.", "RAID")
                        print("Player 4 running total: Blackjack") 
                    end
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            elseif player4RunningTotalDAO == 20 then
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end
            else
                SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                print("Player 4 running total: " .. player4RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Player 4: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 13. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 4 then -- Player 4: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 98, -35)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 14. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 5 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 5 then -- Player 4: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 88, -45)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 15. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 6 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 6 then -- Player 4: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 78, -55)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 16. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 7 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 7 then -- Player 4: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 68, -65)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 17. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 18. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 19. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. " or 20. What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO .. " or 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 8 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ". What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 8 then -- Player 4: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 101, -19)
            
            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                        print("Player 4 (H1) running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage("Hand 1: " .. unitName4DAO .. " has Blackjack.", "RAID")
                        print("Player 4 (H1) running total: Blackjack") 
                    end
                end
            else
                SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
            end

        elseif turnDAO == 9 then -- Player 4: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 133, -28)
            
            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "2 or 12"
                if player4S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 12")
                -- Player 4: "3 or 13"
                elseif player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                        print("Player 4 (H2) running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage("Hand 2: " .. unitName4DAO .. " has Blackjack.", "RAID")
                        print("Player 4 (H2) running total: Blackjack")  
                    end
                end
            else
                SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
            end

            if dealerFrameDAO.player4SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
            end

        elseif turnDAO == 10 then -- Player 4: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 4: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 81, -39)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                end
            else
                if player4S1RunningTotalDAO >= 5 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 4: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 71, -49)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                end
            else
                if player4S1RunningTotalDAO >= 6 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 4: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 61, -59)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                end
            else
                if player4S1RunningTotalDAO >= 7 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 4: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 51, -69)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 8 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                    
                end
            end
            
            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                turnDAO = 22 -- Skip to Dealer 2nd Card
            else
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
            end

        elseif turnDAO == 15 then -- Player 4: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 91, -29)

            if player4S1RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H1) running total: 13")
                -- Player 4: "14"
                elseif player4S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H1) running total: 14")
                -- Player 4: "15" 
                elseif player4S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H1) running total: 15")
                -- Player 4: "16"
                elseif player4S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H1) running total: 16")
                -- Player 4: "17"
                elseif player4S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H1) running total: 17")
                -- Player 4: "18"
                elseif player4S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H1) running total: 18")
                -- Player 4: "19"
                elseif player4S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H1) running total: 19")
                -- Player 4: "20"
                elseif player4S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H1) running total: 20")
                -- Player 4: "21"
                elseif player4S1RunningTotalDAO == 11 or player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                elseif player4S1RunningTotalDAO >= 12 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S1RunningTotalDAO >= 4 and player4S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has " .. player4S1RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H1) running total: " .. player4S1RunningTotalDAO)
                elseif player4S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName4DAO .. " has gone bust with a total of " .. player4S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player4SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                turnDAO = 22 -- Skip to Dealer 2nd Card
            else
                SendChatMessage("(H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                turnDAO = 15 -- Skip to Player 4 3rd Card (Split H2)
            end

        elseif turnDAO == 16 then -- Player 4: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "3 or 13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 13")
                -- Player 4: "4 or 14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 17 then -- Player 4: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 113, -48)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "4 or 14"
                if player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 14")
                -- Player 4: "5 or 15"
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 5 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 18 then -- Player 4: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 103, -58)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "5 or 15"
                if player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 15")
                -- Player 4: "6 or 16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 6 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 19 then -- Player 4: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 93, -68)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "6 or 16"
                if player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 16")
                -- Player 4: "7 or 17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player4S2RunningTotalDAO >= 7 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 20 then -- Player 4: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 83, -78)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "7 or 17"
                if player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 17")
                -- Player 4: "8 or 18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 18")
                -- Player 4: "9 or 19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 19")
                -- Player 4: "10 or 20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO .. " or 20")
                -- Player 4: "Blackjack"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 8 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName4DAO .. "?", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            turnDAO = 22 -- Skip to Dealer 2nd Card

        elseif turnDAO == 21 then -- Player 4: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 123, -38)

            if player4S2RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 (H2) running total: 13")
                -- Player 4: "14"
                elseif player4S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 (H2) running total: 14")
                -- Player 4: "15" 
                elseif player4S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 (H2) running total: 15")
                -- Player 4: "16"
                elseif player4S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 (H2) running total: 16")
                -- Player 4: "17"
                elseif player4S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 (H2) running total: 17")
                -- Player 4: "18"
                elseif player4S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 (H2) running total: 18")
                -- Player 4: "19"
                elseif player4S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 (H2) running total: 19")
                -- Player 4: "20"
                elseif player4S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 (H2) running total: 20")
                -- Player 4: "21"
                elseif player4S2RunningTotalDAO == 11 or player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                elseif player4S2RunningTotalDAO >= 12 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4S2RunningTotalDAO >= 4 and player4S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has " .. player4S2RunningTotalDAO .. ".", "RAID")
                    print("Player 4 (H2) running total: " .. player4S2RunningTotalDAO)
                elseif player4S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName4DAO .. " has gone bust with a total of " .. player4S2RunningTotalDAO .. ".", "RAID")
                end
            end
            turnDAO = 22 -- Skip to Dealer 2nd Card

        elseif turnDAO == 22 then -- Player 4: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 108, -25)

            if player4RunningTotalWithAceDAO >= 1 then

                -- Player 4: "13"
                if player4RunningTotalDAO == 3 then
                    SendChatMessage(unitName4DAO .. " has 13.", "RAID")
                    print("Player 4 running total: 13")
                -- Player 4: "14"
                elseif player4RunningTotalDAO == 4 then
                    SendChatMessage(unitName4DAO .. " has 14.", "RAID")
                    print("Player 4 running total: 14")
                -- Player 4: "15" 
                elseif player4RunningTotalDAO == 5 then
                    SendChatMessage(unitName4DAO .. " has 15.", "RAID")
                    print("Player 4 running total: 15")
                -- Player 4: "16"
                elseif player4RunningTotalDAO == 6 then
                    SendChatMessage(unitName4DAO .. " has 16.", "RAID")
                    print("Player 4 running total: 16")
                -- Player 4: "17"
                elseif player4RunningTotalDAO == 7 then
                    SendChatMessage(unitName4DAO .. " has 17.", "RAID")
                    print("Player 4 running total: 17")
                -- Player 4: "18"
                elseif player4RunningTotalDAO == 8 then
                    SendChatMessage(unitName4DAO .. " has 18.", "RAID")
                    print("Player 4 running total: 18")
                -- Player 4: "19"
                elseif player4RunningTotalDAO == 9 then
                    SendChatMessage(unitName4DAO .. " has 19.", "RAID")
                    print("Player 4 running total: 19")
                -- Player 4: "20"
                elseif player4RunningTotalDAO == 10 then
                    SendChatMessage(unitName4DAO .. " has 20.", "RAID")
                    print("Player 4 running total: 20")
                -- Player 4: "21"
                elseif player4RunningTotalDAO == 11 or player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                elseif player4RunningTotalDAO >= 12 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            else
                if player4RunningTotalDAO >= 4 and player4RunningTotalDAO <= 20 then
                    SendChatMessage(unitName4DAO .. " has " .. player4RunningTotalDAO .. ".", "RAID")
                    print("Player 4 running total: " .. player4RunningTotalDAO)
                elseif player4RunningTotalDAO == 21 then
                    SendChatMessage(unitName4DAO .. " has 21.", "RAID")
                    print("Player 4 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName4DAO .. " has gone bust with a total of " .. player4RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 23 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 24 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 25 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 26 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 27 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 28 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard3DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 3
    if not player1ActiveDAO and not player2ActiveDAO and player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 3: 1st Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 2 then -- Player 3: 2nd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Player 3: 3rd Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 3: 4th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 3: 5th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 3: 6th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 3: 7th Card
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 3: 2nd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 3: 2nd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 3: 3rd Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 3: 4th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 3: 5th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 3: 6th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 3: 7th Card (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 3: Double (3rd Card) (Split H1)
                player3S1RunningTotalDAO = player3S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S1RunningTotalWithAceDAO = player3S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 3: 3rd Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 3: 4th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 3: 5th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 3: 6th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 3: 7th Card (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 3: Double (3rd Card) (Split H2)
                player3S2RunningTotalDAO = player3S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3S2RunningTotalWithAceDAO = player3S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 3: Double (3rd Card)
                player3RunningTotalDAO = player3RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName3DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player3RunningTotalWithAceDAO = player3RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 3: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, 15)
            if player3RunningTotalDAO == 1 then
                print("Player 3 running total: " .. player3RunningTotalDAO .. " or " .. player3RunningTotalWithAceDAO)
            else
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end
        
        elseif turnDAO == 1 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 2 then -- Player 3: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, 5)
            
            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3RunningTotalDAO == 2 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 12. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                        print("Player 3 running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage(unitName3DAO .. " has Blackjack.", "RAID")
                        print("Player 3 running total: Blackjack") 
                    end
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            elseif player3RunningTotalDAO == 20 then
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end
            else
                SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                print("Player 3 running total: " .. player3RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Player 3: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 13. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 4 then -- Player 3: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -20, -15)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 14. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 5 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 5 then -- Player 3: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -25)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 15. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 6 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 6 then -- Player 3: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 0, -35)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 16. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 7 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 7 then -- Player 3: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 10, -45)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 17. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 18. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 19. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. " or 20. What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO .. " or 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 8 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ". What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 8 then -- Player 3: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -2)
            
            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                        print("Player 3 (H1) running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage("Hand 1: " .. unitName3DAO .. " has Blackjack.", "RAID")
                        print("Player 3 (H1) running total: Blackjack") 
                    end
                end
            else
                SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
            end

        elseif turnDAO == 9 then -- Player 3: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)
            
            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "2 or 12"
                if player3S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 12")
                -- Player 3: "3 or 13"
                elseif player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                        print("Player 3 (H2) running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage("Hand 2: " .. unitName3DAO .. " has Blackjack.", "RAID")
                        print("Player 3 (H2) running total: Blackjack")  
                    end
                end
            else
                SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
            end

            if dealerFrameDAO.player3SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
            end

        elseif turnDAO == 10 then -- Player 3: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 3: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -34, -22)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                end
            else
                if player3S1RunningTotalDAO >= 5 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 3: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -32)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                end
            else
                if player3S1RunningTotalDAO >= 6 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 3: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -14, -42)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                end
            else
                if player3S1RunningTotalDAO >= 7 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 3: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -4, -52)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 8 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                turnDAO = 22 -- Skip to Dealer 2nd Card
            else
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
            end

        elseif turnDAO == 15 then -- Player 3: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -24, -12)

            if player3S1RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H1) running total: 13")
                -- Player 3: "14"
                elseif player3S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H1) running total: 14")
                -- Player 3: "15" 
                elseif player3S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H1) running total: 15")
                -- Player 3: "16"
                elseif player3S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H1) running total: 16")
                -- Player 3: "17"
                elseif player3S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H1) running total: 17")
                -- Player 3: "18"
                elseif player3S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H1) running total: 18")
                -- Player 3: "19"
                elseif player3S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H1) running total: 19")
                -- Player 3: "20"
                elseif player3S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H1) running total: 20")
                -- Player 3: "21"
                elseif player3S1RunningTotalDAO == 11 or player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                elseif player3S1RunningTotalDAO >= 12 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S1RunningTotalDAO >= 4 and player3S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has " .. player3S1RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H1) running total: " .. player3S1RunningTotalDAO)
                elseif player3S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName3DAO .. " has gone bust with a total of " .. player3S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player3SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                turnDAO = 22 -- Skip to Dealer 2nd Card
            else
                SendChatMessage("(H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                turnDAO = 15 -- Skip to Player 3 3rd Card (Split H2)
            end

        elseif turnDAO == 16 then -- Player 3: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "3 or 13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 13")
                -- Player 3: "4 or 14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 17 then -- Player 3: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 60, -22)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "4 or 14"
                if player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 14")
                -- Player 3: "5 or 15"
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 5 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 18 then -- Player 3: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "5 or 15"
                if player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 15")
                -- Player 3: "6 or 16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 6 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 19 then -- Player 3: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 40, -2)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "6 or 16"
                if player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 16")
                -- Player 3: "7 or 17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player3S2RunningTotalDAO >= 7 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 20 then -- Player 3: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 30, 8)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "7 or 17"
                if player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 17")
                -- Player 3: "8 or 18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 18")
                -- Player 3: "9 or 19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 19")
                -- Player 3: "10 or 20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO .. " or 20")
                -- Player 3: "Blackjack"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 8 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName3DAO .. "?", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            turnDAO = 22 -- Skip to Dealer 2nd Card

        elseif turnDAO == 21 then -- Player 3: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 50, -12)

            if player3S2RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 (H2) running total: 13")
                -- Player 3: "14"
                elseif player3S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 (H2) running total: 14")
                -- Player 3: "15" 
                elseif player3S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 (H2) running total: 15")
                -- Player 3: "16"
                elseif player3S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 (H2) running total: 16")
                -- Player 3: "17"
                elseif player3S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 (H2) running total: 17")
                -- Player 3: "18"
                elseif player3S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 (H2) running total: 18")
                -- Player 3: "19"
                elseif player3S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 (H2) running total: 19")
                -- Player 3: "20"
                elseif player3S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 (H2) running total: 20")
                -- Player 3: "21"
                elseif player3S2RunningTotalDAO == 11 or player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                elseif player3S2RunningTotalDAO >= 12 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3S2RunningTotalDAO >= 4 and player3S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has " .. player3S2RunningTotalDAO .. ".", "RAID")
                    print("Player 3 (H2) running total: " .. player3S2RunningTotalDAO)
                elseif player3S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName3DAO .. " has gone bust with a total of " .. player3S2RunningTotalDAO .. ".", "RAID")
                end
            end
            turnDAO = 22 -- Skip to Dealer 2nd Card

        elseif turnDAO == 22 then -- Player 3: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -10, -5)

            if player3RunningTotalWithAceDAO >= 1 then

                -- Player 3: "13"
                if player3RunningTotalDAO == 3 then
                    SendChatMessage(unitName3DAO .. " has 13.", "RAID")
                    print("Player 3 running total: 13")
                -- Player 3: "14"
                elseif player3RunningTotalDAO == 4 then
                    SendChatMessage(unitName3DAO .. " has 14.", "RAID")
                    print("Player 3 running total: 14")
                -- Player 3: "15" 
                elseif player3RunningTotalDAO == 5 then
                    SendChatMessage(unitName3DAO .. " has 15.", "RAID")
                    print("Player 3 running total: 15")
                -- Player 3: "16"
                elseif player3RunningTotalDAO == 6 then
                    SendChatMessage(unitName3DAO .. " has 16.", "RAID")
                    print("Player 3 running total: 16")
                -- Player 3: "17"
                elseif player3RunningTotalDAO == 7 then
                    SendChatMessage(unitName3DAO .. " has 17.", "RAID")
                    print("Player 3 running total: 17")
                -- Player 3: "18"
                elseif player3RunningTotalDAO == 8 then
                    SendChatMessage(unitName3DAO .. " has 18.", "RAID")
                    print("Player 3 running total: 18")
                -- Player 3: "19"
                elseif player3RunningTotalDAO == 9 then
                    SendChatMessage(unitName3DAO .. " has 19.", "RAID")
                    print("Player 3 running total: 19")
                -- Player 3: "20"
                elseif player3RunningTotalDAO == 10 then
                    SendChatMessage(unitName3DAO .. " has 20.", "RAID")
                    print("Player 3 running total: 20")
                -- Player 3: "21"
                elseif player3RunningTotalDAO == 11 or player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                elseif player3RunningTotalDAO >= 12 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            else
                if player3RunningTotalDAO >= 4 and player3RunningTotalDAO <= 20 then
                    SendChatMessage(unitName3DAO .. " has " .. player3RunningTotalDAO .. ".", "RAID")
                    print("Player 3 running total: " .. player3RunningTotalDAO)
                elseif player3RunningTotalDAO == 21 then
                    SendChatMessage(unitName3DAO .. " has 21.", "RAID")
                    print("Player 3 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName3DAO .. " has gone bust with a total of " .. player3RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 23 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 24 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 25 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 26 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 27 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 28 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard2DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    
    -- Players: 2
    if not player1ActiveDAO and player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 2: 1st Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 2 then -- Player 2: 2nd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Player 2: 3rd Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 2: 4th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 2: 5th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 2: 6th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 2: 7th Card
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 2: 2nd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 2: 2nd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 2: 3rd Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 2: 4th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 2: 5th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 2: 6th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 2: 7th Card (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 2: Double (3rd Card) (Split H1)
                player2S1RunningTotalDAO = player2S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S1RunningTotalWithAceDAO = player2S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 2: 3rd Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 2: 4th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 2: 5th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 2: 6th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 2: 7th Card (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 2: Double (3rd Card) (Split H2)
                player2S2RunningTotalDAO = player2S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2S2RunningTotalWithAceDAO = player2S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 2: Double (3rd Card)
                player2RunningTotalDAO = player2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName2DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player2RunningTotalWithAceDAO = player2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 2: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -105, -5)
            if player2RunningTotalDAO == 1 then
                print("Player 2 running total: " .. player2RunningTotalDAO .. " or " .. player2RunningTotalWithAceDAO)
            else
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end
        
        elseif turnDAO == 1 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 2 then -- Player 2: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -95, -15)
            
            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2RunningTotalDAO == 2 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 12. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                        print("Player 2 running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage(unitName2DAO .. " has Blackjack.", "RAID")
                        print("Player 2 running total: Blackjack") 
                    end
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            elseif player2RunningTotalDAO == 20 then
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end
            else
                SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                print("Player 2 running total: " .. player2RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Player 2: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 13. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 4 then -- Player 2: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -75, -35)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 14. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 5 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 5 then -- Player 2: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -65, -45)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 15. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 6 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 6 then -- Player 2: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -55, -55)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 16. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 7 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 7 then -- Player 2: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -45, -65)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 17. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 18. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 19. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. " or 20. What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO .. " or 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 8 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ". What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 8 then -- Player 2: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -110, -28)
            
            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                        print("Player 2 (H1) running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage("Hand 1: " .. unitName2DAO .. " has Blackjack.", "RAID")
                        print("Player 2 (H1) running total: Blackjack") 
                    end
                end
            else
                SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
            end

        elseif turnDAO == 9 then -- Player 2: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -78, -19)
            
            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "2 or 12"
                if player2S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 12")
                -- Player 2: "3 or 13"
                elseif player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                        print("Player 2 (H2) running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage("Hand 2: " .. unitName2DAO .. " has Blackjack.", "RAID")
                        print("Player 2 (H2) running total: Blackjack")  
                    end
                end
            else
                SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
            end

            if dealerFrameDAO.player2SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
            end

        elseif turnDAO == 10 then -- Player 2: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 2: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -90, -48)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                end
            else
                if player2S1RunningTotalDAO >= 5 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 2: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -80, -58)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                end
            else
                if player2S1RunningTotalDAO >= 6 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 2: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -70, -68)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                end
            else
                if player2S1RunningTotalDAO >= 7 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 2: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -60, -78)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 8 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                turnDAO = 22 -- Skip to Dealer 2nd Card
            else
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
            end

        elseif turnDAO == 15 then -- Player 2: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -100, -38)

            if player2S1RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H1) running total: 13")
                -- Player 2: "14"
                elseif player2S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H1) running total: 14")
                -- Player 2: "15" 
                elseif player2S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H1) running total: 15")
                -- Player 2: "16"
                elseif player2S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H1) running total: 16")
                -- Player 2: "17"
                elseif player2S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H1) running total: 17")
                -- Player 2: "18"
                elseif player2S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H1) running total: 18")
                -- Player 2: "19"
                elseif player2S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H1) running total: 19")
                -- Player 2: "20"
                elseif player2S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H1) running total: 20")
                -- Player 2: "21"
                elseif player2S1RunningTotalDAO == 11 or player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                elseif player2S1RunningTotalDAO >= 12 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S1RunningTotalDAO >= 4 and player2S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has " .. player2S1RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H1) running total: " .. player2S1RunningTotalDAO)
                elseif player2S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName2DAO .. " has gone bust with a total of " .. player2S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player2SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                turnDAO = 22 -- Skip to Dealer 2nd Card
            else
                SendChatMessage("(H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                turnDAO = 15 -- Skip to Player 2 3rd Card (Split H2)
            end

        elseif turnDAO == 16 then -- Player 2: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "3 or 13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 13")
                -- Player 2: "4 or 14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 17 then -- Player 2: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -58, -39)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "4 or 14"
                if player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 14")
                -- Player 2: "5 or 15"
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player2S2RunningTotalDAO >= 5 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 18 then -- Player 2: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -49)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "5 or 15"
                if player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 15")
                -- Player 2: "6 or 16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player2S2RunningTotalDAO >= 6 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 19 then -- Player 2: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -59)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "6 or 16"
                if player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 16")
                -- Player 2: "7 or 17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player2S2RunningTotalDAO >= 7 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 20 then -- Player 2: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -69)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "7 or 17"
                if player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 17")
                -- Player 2: "8 or 18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 18")
                -- Player 2: "9 or 19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 19")
                -- Player 2: "10 or 20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO .. " or 20")
                -- Player 2: "Blackjack"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 8 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName2DAO .. "?", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            turnDAO = 22 -- Skip to Dealer 2nd Card

        elseif turnDAO == 21 then -- Player 2: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -68, -29)

            if player2S2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 (H2) running total: 13")
                -- Player 2: "14"
                elseif player2S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 (H2) running total: 14")
                -- Player 2: "15" 
                elseif player2S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 (H2) running total: 15")
                -- Player 2: "16"
                elseif player2S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 (H2) running total: 16")
                -- Player 2: "17"
                elseif player2S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 (H2) running total: 17")
                -- Player 2: "18"
                elseif player2S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 (H2) running total: 18")
                -- Player 2: "19"
                elseif player2S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 (H2) running total: 19")
                -- Player 2: "20"
                elseif player2S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 (H2) running total: 20")
                -- Player 2: "21"
                elseif player2S2RunningTotalDAO == 11 or player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                elseif player2S2RunningTotalDAO >= 12 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2S2RunningTotalDAO >= 4 and player2S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has " .. player2S2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 (H2) running total: " .. player2S2RunningTotalDAO)
                elseif player2S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName2DAO .. " has gone bust with a total of " .. player2S2RunningTotalDAO .. ".", "RAID")
                end
            end
            turnDAO = 22 -- Skip to Dealer 2nd Card

        elseif turnDAO == 22 then -- Player 2: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -85, -25)

            if player2RunningTotalWithAceDAO >= 1 then

                -- Player 2: "13"
                if player2RunningTotalDAO == 3 then
                    SendChatMessage(unitName2DAO .. " has 13.", "RAID")
                    print("Player 2 running total: 13")
                -- Player 2: "14"
                elseif player2RunningTotalDAO == 4 then
                    SendChatMessage(unitName2DAO .. " has 14.", "RAID")
                    print("Player 2 running total: 14")
                -- Player 2: "15" 
                elseif player2RunningTotalDAO == 5 then
                    SendChatMessage(unitName2DAO .. " has 15.", "RAID")
                    print("Player 2 running total: 15")
                -- Player 2: "16"
                elseif player2RunningTotalDAO == 6 then
                    SendChatMessage(unitName2DAO .. " has 16.", "RAID")
                    print("Player 2 running total: 16")
                -- Player 2: "17"
                elseif player2RunningTotalDAO == 7 then
                    SendChatMessage(unitName2DAO .. " has 17.", "RAID")
                    print("Player 2 running total: 17")
                -- Player 2: "18"
                elseif player2RunningTotalDAO == 8 then
                    SendChatMessage(unitName2DAO .. " has 18.", "RAID")
                    print("Player 2 running total: 18")
                -- Player 2: "19"
                elseif player2RunningTotalDAO == 9 then
                    SendChatMessage(unitName2DAO .. " has 19.", "RAID")
                    print("Player 2 running total: 19")
                -- Player 2: "20"
                elseif player2RunningTotalDAO == 10 then
                    SendChatMessage(unitName2DAO .. " has 20.", "RAID")
                    print("Player 2 running total: 20")
                -- Player 2: "21"
                elseif player2RunningTotalDAO == 11 or player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                elseif player2RunningTotalDAO >= 12 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player2RunningTotalDAO >= 4 and player2RunningTotalDAO <= 20 then
                    SendChatMessage(unitName2DAO .. " has " .. player2RunningTotalDAO .. ".", "RAID")
                    print("Player 2 running total: " .. player2RunningTotalDAO)
                elseif player2RunningTotalDAO == 21 then
                    SendChatMessage(unitName2DAO .. " has 21.", "RAID")
                    print("Player 2 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName2DAO .. " has gone bust with a total of " .. player2RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 23 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 24 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 25 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 26 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 27 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 28 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end
function DisplayRandomCard1DAO(drawnCardDAO, rollResultDAO)
    local cardImageDAO = dealerFrameDAO:CreateTexture(nil, "OVERLAY")
    cardImageDAO:SetSize(24, 48)

    local cardCodeDAO = nil
    for codeDAO, nameDAO in pairs(cardNamesDAO) do
        if nameDAO == drawnCardDAO then
            cardCodeDAO = codeDAO
            break
        end
    end

    local cardNameDAO
    if cardCodeDAO then
        cardNameDAO = cardCodeDAO
    else
        cardNameDAO = drawnCardDAO
    end

    local imageNameDAO = "Interface\\AddOns\\Blackjack_Retail\\ImagesDAO\\" .. cardCodeDAO
    cardImageDAO:SetTexture(imageNameDAO)

    local cardValueDAO = cardValuesDAO[cardCodeDAO]
    local previousRollDAO = currentRollDAO + 1

    print("Result: " .. rollResultDAO .. " | Card: " .. rollResultDAO .. " / " .. previousRollDAO .. " | Name: " .. drawnCardDAO .. " | Image: " .. cardCodeDAO)
    print(drawnCardDAO .. " has been removed from the shoe | " .. currentRollDAO .. " cards remaining")
    -- Players: 1
    if player1ActiveDAO and not player2ActiveDAO and not player3ActiveDAO and not player4ActiveDAO and not player5ActiveDAO then
        if cardValueDAO then
            if turnDAO == 0 then -- Player 1: 1st Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 1 then -- Dealer: 1st Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                    InsuranceTriggerDAO()
                end
            elseif turnDAO == 2 then -- Player 1: 2nd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 3 then -- Player 1: 3rd Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 4 then -- Player 1: 4th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 5 then -- Player 1: 5th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 6 then -- Player 1: 6th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 7 then -- Player 1: 7th Card
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 8 then -- Player 1: 2nd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 9 then -- Player 1: 2nd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 10 then -- Player 1: 3rd Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 11 then -- Player 1: 4th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 12 then -- Player 1: 5th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 13 then -- Player 1: 6th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 14 then -- Player 1: 7th Card (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 15 then -- Player 1: Double (3rd Card) (Split H1)
                player1S1RunningTotalDAO = player1S1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S1RunningTotalWithAceDAO = player1S1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 16 then -- Player 1: 3rd Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 17 then -- Player 1: 4th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 18 then -- Player 1: 5th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 19 then -- Player 1: 6th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 20 then -- Player 1: 7th Card (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 21 then -- Player 1: Double (3rd Card) (Split H2)
                player1S2RunningTotalDAO = player1S2RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1S2RunningTotalWithAceDAO = player1S2RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 22 then -- Player 1: Double (3rd Card)
                player1RunningTotalDAO = player1RunningTotalDAO + cardValueDAO[1]
                SendChatMessage(unitName1DAO .. " received the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then
                    player1RunningTotalWithAceDAO = player1RunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 23 then -- Dealer: 2nd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 24 then -- Dealer: 3rd Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 25 then -- Dealer: 4th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 26 then -- Dealer: 5th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 27 then -- Dealer: 6th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            elseif turnDAO == 28 then -- Dealer: 7th Card
                dealerRunningTotalDAO = dealerRunningTotalDAO + cardValueDAO[1]
                SendChatMessage("Dealer has turned the " .. drawnCardDAO, "RAID")
                if cardValueDAO[2] then -- Dealer: Ace
                    dealerRunningTotalWithAceDAO = dealerRunningTotalDAO + cardValueDAO[2]
                end
            end
        end

        if turnDAO == 0 then -- Player 1: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -205, -75)
            if player1RunningTotalDAO == 1 then
                print("Player 1 running total: " .. player1RunningTotalDAO .. " or " .. player1RunningTotalWithAceDAO)
            else
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end
        
        elseif turnDAO == 1 then -- Dealer: 1st Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 12, -150)
            if dealerRunningTotalDAO == 1 then
                print("Dealer running total: " .. dealerRunningTotalDAO .. " or " .. dealerRunningTotalWithAceDAO)
            else
                print("Dealer running total: " .. dealerRunningTotalDAO)
            end
    
        elseif turnDAO == 2 then -- Player 1: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -195, -85)
            
            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1RunningTotalDAO == 2 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 12. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                        print("Player 1 running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage(unitName1DAO .. " has Blackjack.", "RAID")
                        print("Player 1 running total: Blackjack") 
                    end
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            elseif player1RunningTotalDAO == 20 then
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end
            else
                SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                print("Player 1 running total: " .. player1RunningTotalDAO)
            end

        elseif turnDAO == 3 then -- Player 1: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 13. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 4 then -- Player 1: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -175, -105)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 14. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 5 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 5 then -- Player 1: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -165, -115)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 15. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 6 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 6 then -- Player 1: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -155, -125)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 16. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 7 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 7 then -- Player 1: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -145, -135)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 17. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 18. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 19. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. " or 20. What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO .. " or 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 8 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ". What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 8 then -- Player 1: 2nd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -200, -115)
            
            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S1RunningTotalDAO == 2 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                        print("Player 1 (H1) running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage("Hand 1: " .. unitName1DAO .. " has Blackjack.", "RAID")
                        print("Player 1 (H1) running total: Blackjack") 
                    end
                end
            else
                SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
            end

        elseif turnDAO == 9 then -- Player 1: 2nd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -80)
            
            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "2 or 12"
                if player1S2RunningTotalDAO == 2 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 12.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 12")
                -- Player 1: "3 or 13"
                elseif player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20.", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 then
                    if dealerRunningTotalDAO == 10 or dealerRunningTotalDAO == 1 then
                        SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                        print("Player 1 (H2) running total: Blackjack - game is not over yet though")
                    else
                        SendChatMessage("Hand 2: " .. unitName1DAO .. " has Blackjack.", "RAID")
                        print("Player 1 (H2) running total: Blackjack")  
                    end
                end
            else
                SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
            end

            if dealerFrameDAO.player1SplitHand1CardTotalTextDAO:GetText() == "Blackjack" then
                if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                end
            else
                SendChatMessage("(H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
            end

        elseif turnDAO == 10 then -- Player 1: 3rd Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 13. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                end
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 11 then -- Player 1: 4th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -180, -135)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 14. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                end
            else
                if player1S1RunningTotalDAO >= 5 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 12 then -- Player 1: 5th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -170, -145)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 15. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                end
            else
                if player1S1RunningTotalDAO >= 6 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 13 then -- Player 1: 6th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -155)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 16. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                end
            else
                if player1S1RunningTotalDAO >= 7 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                    if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                        turnDAO = 22 -- Skip to Dealer 2nd Card
                    else
                        SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                        turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
                    end
                end
            end

        elseif turnDAO == 14 then -- Player 1: 7th Card (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -165)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 17. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 18. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 19. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. " or 20. (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S1RunningTotalDAO >= 8 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ". (H1) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            end
            
            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                turnDAO = 22 -- Skip to Dealer 2nd Card
            else
                SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
            end

        elseif turnDAO == 15 then -- Player 1: 3rd Card (Double) (Split H1)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -190, -125)

            if player1S1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S1RunningTotalDAO == 3 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H1) running total: 13")
                -- Player 1: "14"
                elseif player1S1RunningTotalDAO == 4 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H1) running total: 14")
                -- Player 1: "15" 
                elseif player1S1RunningTotalDAO == 5 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H1) running total: 15")
                -- Player 1: "16"
                elseif player1S1RunningTotalDAO == 6 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H1) running total: 16")
                -- Player 1: "17"
                elseif player1S1RunningTotalDAO == 7 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H1) running total: 17")
                -- Player 1: "18"
                elseif player1S1RunningTotalDAO == 8 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H1) running total: 18")
                -- Player 1: "19"
                elseif player1S1RunningTotalDAO == 9 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H1) running total: 19")
                -- Player 1: "20"
                elseif player1S1RunningTotalDAO == 10 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H1) running total: 20")
                -- Player 1: "21"
                elseif player1S1RunningTotalDAO == 11 or player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                elseif player1S1RunningTotalDAO >= 12 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S1RunningTotalDAO >= 4 and player1S1RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has " .. player1S1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H1) running total: " .. player1S1RunningTotalDAO)
                elseif player1S1RunningTotalDAO == 21 then
                    SendChatMessage("Hand 1: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H1) running total: 21")
                else
                    SendChatMessage("{cross} Hand 1: " .. unitName1DAO .. " has gone bust with a total of " .. player1S1RunningTotalDAO .. ".", "RAID")
                end
            end

            if dealerFrameDAO.player1SplitHand2CardTotalTextDAO:GetText() == "Blackjack" then
                turnDAO = 22 -- Skip to Dealer 2nd Card
            else
                SendChatMessage("(H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                turnDAO = 15 -- Skip to Player 1 3rd Card (Split H2)
            end

        elseif turnDAO == 16 then -- Player 1: 3rd Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "3 or 13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 13. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 13")
                -- Player 1: "4 or 14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 17 then -- Player 1: 4th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -150, -100)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "4 or 14"
                if player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 14. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 14")
                -- Player 1: "5 or 15"
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player1S2RunningTotalDAO >= 5 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 18 then -- Player 1: 5th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -140, -110)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "5 or 15"
                if player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 15. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 15")
                -- Player 1: "6 or 16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player1S2RunningTotalDAO >= 6 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 19 then -- Player 1: 6th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -130, -120)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "6 or 16"
                if player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 16. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 16")
                -- Player 1: "7 or 17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            else
                if player1S2RunningTotalDAO >= 7 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                    turnDAO = 22 -- Skip to Dealer 2nd Card
                end
            end

        elseif turnDAO == 20 then -- Player 1: 7th Card (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -120, -130)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "7 or 17"
                if player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 17. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 17")
                -- Player 1: "8 or 18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 18. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 18")
                -- Player 1: "9 or 19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 19. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 19")
                -- Player 1: "10 or 20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. " or 20. (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO .. " or 20")
                -- Player 1: "Blackjack"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S2RunningTotalDAO >= 8 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ". (H2) What is your decision, " .. unitName1DAO .. "?", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end
            turnDAO = 22 -- Skip to Dealer 2nd Card

        elseif turnDAO == 21 then -- Player 1: 3rd Card (Double) (Split H2)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -160, -90)

            if player1S2RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1S2RunningTotalDAO == 3 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 (H2) running total: 13")
                -- Player 1: "14"
                elseif player1S2RunningTotalDAO == 4 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 (H2) running total: 14")
                -- Player 1: "15" 
                elseif player1S2RunningTotalDAO == 5 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 (H2) running total: 15")
                -- Player 1: "16"
                elseif player1S2RunningTotalDAO == 6 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 (H2) running total: 16")
                -- Player 1: "17"
                elseif player1S2RunningTotalDAO == 7 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 (H2) running total: 17")
                -- Player 1: "18"
                elseif player1S2RunningTotalDAO == 8 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 (H2) running total: 18")
                -- Player 1: "19"
                elseif player1S2RunningTotalDAO == 9 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 (H2) running total: 19")
                -- Player 1: "20"
                elseif player1S2RunningTotalDAO == 10 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 (H2) running total: 20")
                -- Player 1: "21"
                elseif player1S2RunningTotalDAO == 11 or player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                elseif player1S2RunningTotalDAO >= 12 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1S2RunningTotalDAO >= 4 and player1S2RunningTotalDAO <= 20 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has " .. player1S2RunningTotalDAO .. ".", "RAID")
                    print("Player 1 (H2) running total: " .. player1S2RunningTotalDAO)
                elseif player1S2RunningTotalDAO == 21 then
                    SendChatMessage("Hand 2: " .. unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 (H2) running total: 21")
                else
                    SendChatMessage("{cross} Hand 2: " .. unitName1DAO .. " has gone bust with a total of " .. player1S2RunningTotalDAO .. ".", "RAID")
                end
            end
            turnDAO = 22 -- Skip to Dealer 2nd Card

        elseif turnDAO == 22 then -- Player 1: 3rd Card (Double)
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -185, -95)

            if player1RunningTotalWithAceDAO >= 1 then

                -- Player 1: "13"
                if player1RunningTotalDAO == 3 then
                    SendChatMessage(unitName1DAO .. " has 13.", "RAID")
                    print("Player 1 running total: 13")
                -- Player 1: "14"
                elseif player1RunningTotalDAO == 4 then
                    SendChatMessage(unitName1DAO .. " has 14.", "RAID")
                    print("Player 1 running total: 14")
                -- Player 1: "15" 
                elseif player1RunningTotalDAO == 5 then
                    SendChatMessage(unitName1DAO .. " has 15.", "RAID")
                    print("Player 1 running total: 15")
                -- Player 1: "16"
                elseif player1RunningTotalDAO == 6 then
                    SendChatMessage(unitName1DAO .. " has 16.", "RAID")
                    print("Player 1 running total: 16")
                -- Player 1: "17"
                elseif player1RunningTotalDAO == 7 then
                    SendChatMessage(unitName1DAO .. " has 17.", "RAID")
                    print("Player 1 running total: 17")
                -- Player 1: "18"
                elseif player1RunningTotalDAO == 8 then
                    SendChatMessage(unitName1DAO .. " has 18.", "RAID")
                    print("Player 1 running total: 18")
                -- Player 1: "19"
                elseif player1RunningTotalDAO == 9 then
                    SendChatMessage(unitName1DAO .. " has 19.", "RAID")
                    print("Player 1 running total: 19")
                -- Player 1: "20"
                elseif player1RunningTotalDAO == 10 then
                    SendChatMessage(unitName1DAO .. " has 20.", "RAID")
                    print("Player 1 running total: 20")
                -- Player 1: "21"
                elseif player1RunningTotalDAO == 11 or player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                elseif player1RunningTotalDAO >= 12 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO >= 22 then
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            else
                if player1RunningTotalDAO >= 4 and player1RunningTotalDAO <= 20 then
                    SendChatMessage(unitName1DAO .. " has " .. player1RunningTotalDAO .. ".", "RAID")
                    print("Player 1 running total: " .. player1RunningTotalDAO)
                elseif player1RunningTotalDAO == 21 then
                    SendChatMessage(unitName1DAO .. " has 21.", "RAID")
                    print("Player 1 running total: 21")
                else
                    SendChatMessage("{cross} " .. unitName1DAO .. " has gone bust with a total of " .. player1RunningTotalDAO .. ".", "RAID")
                end
            end

        elseif turnDAO == 23 then -- Dealer: 2nd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, 2, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "2 or 12"
                if dealerRunningTotalDAO == 2 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 12.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 12")
                -- Dealer: "3 or 13"
                elseif dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15"
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "Blackjack"
                elseif dealerRunningTotalDAO == 11 then
                    SendChatMessage("Dealer got Blackjack.", "RAID")
                    print("Dealer running total: Blackjack")
                end
            else
                if dealerRunningTotalDAO >= 4 and dealerRunningTotalDAO <= 21 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 24 then -- Dealer: 3rd Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -8, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "3 or 13"
                if dealerRunningTotalDAO == 3 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 13.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 13")
                -- Dealer: "4 or 14"
                elseif dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 25 then -- Dealer: 4th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -18, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "4 or 14"
                if dealerRunningTotalDAO == 4 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 14.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 14")
                -- Dealer: "5 or 15" 
                elseif dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 26 then -- Dealer: 5th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -28, -150)
            
            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "5 or 15" 
                if dealerRunningTotalDAO == 5 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 15.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 15")
                -- Dealer: "6 or 16"
                elseif dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 27 then -- Dealer: 6th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -38, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "6 or 16"
                if dealerRunningTotalDAO == 6 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. " or 16.", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO .. " or 16")
                -- Dealer: "17"
                elseif dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 7 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end

        elseif turnDAO == 28 then -- Dealer: 7th Card
            cardImageDAO:SetPoint("CENTER", dealerFrameDAO, -48, -150)

            if dealerRunningTotalWithAceDAO >= 1 then

                -- Dealer: "17"
                if dealerRunningTotalDAO == 7 then
                    SendChatMessage("Dealer has 17.", "RAID")
                    print("Dealer running total: 17")
                -- Dealer: "18"
                elseif dealerRunningTotalDAO == 8 then
                    SendChatMessage("Dealer has 18.", "RAID")
                    print("Dealer running total: 18")
                -- Dealer: "19"
                elseif dealerRunningTotalDAO == 9 then
                    SendChatMessage("Dealer has 19.", "RAID")
                    print("Dealer running total: 19")
                -- Dealer: "20"
                elseif dealerRunningTotalDAO == 10 then
                    SendChatMessage("Dealer has 20.", "RAID")
                    print("Dealer running total: 20")
                -- Dealer: "21"
                elseif dealerRunningTotalDAO == 11 or dealerRunningTotalDAO == 21 then
                    SendChatMessage("Dealer has 21.", "RAID")
                    print("Dealer running total: 21")
                -- Dealer: "12 - 20"
                elseif dealerRunningTotalDAO >= 12 and dealerRunningTotalDAO <= 20 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                -- Dealer: "22 +"
                elseif dealerRunningTotalDAO >= 22 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            else
                if dealerRunningTotalDAO >= 8 then
                    SendChatMessage("Dealer has " .. dealerRunningTotalDAO .. ".", "RAID")
                    print("Dealer running total: " .. dealerRunningTotalDAO)
                end
            end
        end
    end

    table.insert(cardImagesDAO, cardImageDAO)
    table.insert(dealtCardsDAO, cardNamesDAO[cardCodeDAO])
    turnDAO = turnDAO + 1

end










local function HandleChatMessage12345DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 5 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 6 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 112 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12345DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage2345DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 5 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 90 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2345DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage1345DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 5 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 90 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1345DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage1245DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 5 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 90 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1245DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage1235DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 5 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 90 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1235DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage1234DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 5 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 90 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1234DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage345DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 68 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer345DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage245DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 68 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer245DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage235DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 68 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer235DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage234DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 68 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer234DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage145DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 68 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer145DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage135DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 68 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer135DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage134DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 68 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer134DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage125DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 68 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer125DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage124DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 68 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer124DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage123DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 4 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 68 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer123DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage45DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 46 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer45DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage35DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 46 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer35DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage34DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 46 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer34DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage25DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 46 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer25DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage24DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 46 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer24DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage23DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 46 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer23DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage15DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 46 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer15DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage14DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 46 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer14DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage13DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 46 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer13DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage12DAO(messageDAO)

    print("[HandleChatMessage12DAO] turnDAO =", turnDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end
    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end

    elseif turnDAO == 3 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 46 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer12DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage5DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player5CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
        end

    elseif unitName5DAO and string.find(messageDAO, unitName5DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[94])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player5LossDAO()
                player5InsuranceLossDAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player5LossDAO()
                player5InsuranceLossDAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player5LossDAO()
                player5InsuranceLossDAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player5LossDAO()
                player5InsuranceLossDAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player5LossDAO()
                player5InsuranceLossDAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player5LossDAO()
                player5InsuranceLossDAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player5LossDAO()
                player5InsuranceLossDAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player5LossDAO()
                player5InsuranceLossDAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[98])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player5CardTotalTextDAO:SetTextColor(1, 0, 0)
                player5MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player5LossDAO()
                player5InsuranceLossDAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player5CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[94])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[98])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player5Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player5SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 24 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer5DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage4DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player4CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
        end

    elseif unitName4DAO and string.find(messageDAO, unitName4DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[80])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player4LossDAO()
                player4InsuranceLossDAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player4LossDAO()
                player4InsuranceLossDAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player4LossDAO()
                player4InsuranceLossDAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player4LossDAO()
                player4InsuranceLossDAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player4LossDAO()
                player4InsuranceLossDAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player4LossDAO()
                player4InsuranceLossDAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player4LossDAO()
                player4InsuranceLossDAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player4LossDAO()
                player4InsuranceLossDAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[84])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player4CardTotalTextDAO:SetTextColor(1, 0, 0)
                player4MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player4LossDAO()
                player4InsuranceLossDAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player4CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[80])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[84])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player4Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player4SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 24 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer4DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage3DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player3CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
        end

    elseif unitName3DAO and string.find(messageDAO, unitName3DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[66])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player3LossDAO()
                player3InsuranceLossDAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player3LossDAO()
                player3InsuranceLossDAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player3LossDAO()
                player3InsuranceLossDAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player3LossDAO()
                player3InsuranceLossDAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player3LossDAO()
                player3InsuranceLossDAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player3LossDAO()
                player3InsuranceLossDAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player3LossDAO()
                player3InsuranceLossDAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player3LossDAO()
                player3InsuranceLossDAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[70])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player3CardTotalTextDAO:SetTextColor(1, 0, 0)
                player3MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player3LossDAO()
                player3InsuranceLossDAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player3CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[66])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[70])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player3Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player3SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 24 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer3DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage2DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player2CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
        end

    elseif unitName2DAO and string.find(messageDAO, unitName2DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[52])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player2LossDAO()
                player2InsuranceLossDAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player2LossDAO()
                player2InsuranceLossDAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player2LossDAO()
                player2InsuranceLossDAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player2LossDAO()
                player2InsuranceLossDAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player2LossDAO()
                player2InsuranceLossDAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player2LossDAO()
                player2InsuranceLossDAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player2LossDAO()
                player2InsuranceLossDAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player2LossDAO()
                player2InsuranceLossDAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[56])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player2CardTotalTextDAO:SetTextColor(1, 0, 0)
                player2MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player2LossDAO()
                player2InsuranceLossDAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player2CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[52])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[56])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player2Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player2SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 24 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer2DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end
local function HandleChatMessage1DAO(messageDAO)

    for cardNameDAO, cardFullName in pairs(cardNamesDAO) do
        dealerFrameDAO.player1CardTotalTextDAO:Show()
        dealerFrameDAO.dealerCardTotalTextDAO:Show()
    end

    if turnDAO == 1 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
        end

    elseif unitName1DAO and string.find(messageDAO, unitName1DAO) and string.find(messageDAO, "has") then
        if not string.find(messageDAO, "Hand 1") and not string.find(messageDAO, "Hand 2") then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[38])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 1, 0)         
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "7 or 17") then
                PlaySoundFile(soundFilePathsDAO[28])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7 or 17")
            elseif string.find(messageDAO, "8 or 18") then
                PlaySoundFile(soundFilePathsDAO[29])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8 or 18")
            elseif string.find(messageDAO, "9 or 19") then
                PlaySoundFile(soundFilePathsDAO[30])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9 or 19")
            elseif string.find(messageDAO, "10 or 20") then
                PlaySoundFile(soundFilePathsDAO[31])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10 or 20")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("17")
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("18")
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("19")
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("20")
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("21")
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("22")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player1LossDAO()
                player1InsuranceLossDAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("23")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player1LossDAO()
                player1InsuranceLossDAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("24")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player1LossDAO()
                player1InsuranceLossDAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("25")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player1LossDAO()
                player1InsuranceLossDAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("26")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player1LossDAO()
                player1InsuranceLossDAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("27")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player1LossDAO()
                player1InsuranceLossDAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("28")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player1LossDAO()
                player1InsuranceLossDAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("29")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player1LossDAO()
                player1InsuranceLossDAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[42])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("30")
                dealerFrameDAO.player1CardTotalTextDAO:SetTextColor(1, 0, 0)
                player1MainBetAmountTextDAO:SetTextColor(1, 0, 0)
                player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)
                player1LossDAO()
                player1InsuranceLossDAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.player1CardTotalTextDAO:SetText("13")
            end

        elseif string.find(messageDAO, "Hand 1") then
            if string.find(messageDAO, "Hand 1") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand1BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand1CardTotalTextDAO:SetText("13")
                end
            end

        elseif string.find(messageDAO, "Hand 2") then
            if string.find(messageDAO, "Hand 2") then
                if string.find(messageDAO, "Blackjack") then
                    PlaySoundFile(soundFilePathsDAO[38])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("Blackjack")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 1, 0)         
                elseif string.find(messageDAO, "2 or 12") then
                    PlaySoundFile(soundFilePathsDAO[23])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("2 or 12")
                elseif string.find(messageDAO, "3 or 13") then
                    PlaySoundFile(soundFilePathsDAO[24])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("3 or 13")
                elseif string.find(messageDAO, "4 or 14") then
                    PlaySoundFile(soundFilePathsDAO[25])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4 or 14")
                elseif string.find(messageDAO, "5 or 15") then
                    PlaySoundFile(soundFilePathsDAO[26])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5 or 15")
                elseif string.find(messageDAO, "6 or 16") then
                    PlaySoundFile(soundFilePathsDAO[27])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6 or 16")
                elseif string.find(messageDAO, "7 or 17") then
                    PlaySoundFile(soundFilePathsDAO[28])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7 or 17")
                elseif string.find(messageDAO, "8 or 18") then
                    PlaySoundFile(soundFilePathsDAO[29])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8 or 18")
                elseif string.find(messageDAO, "9 or 19") then
                    PlaySoundFile(soundFilePathsDAO[30])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9 or 19")
                elseif string.find(messageDAO, "10 or 20") then
                    PlaySoundFile(soundFilePathsDAO[31])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10 or 20")
                elseif string.find(messageDAO, "14") then
                    PlaySoundFile(soundFilePathsDAO[14])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("14")
                elseif string.find(messageDAO, "15") then
                    PlaySoundFile(soundFilePathsDAO[15])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("15")
                elseif string.find(messageDAO, "16") then
                    PlaySoundFile(soundFilePathsDAO[16])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("16")
                elseif string.find(messageDAO, "17") then
                    PlaySoundFile(soundFilePathsDAO[17])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("17")
                elseif string.find(messageDAO, "18") then
                    PlaySoundFile(soundFilePathsDAO[18])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("18")
                elseif string.find(messageDAO, "19") then
                    PlaySoundFile(soundFilePathsDAO[19])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("19")
                elseif string.find(messageDAO, "20") then
                    PlaySoundFile(soundFilePathsDAO[20])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("20")
                elseif string.find(messageDAO, "21") then
                    PlaySoundFile(soundFilePathsDAO[21])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("21")
                elseif string.find(messageDAO, "22") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("22")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "23") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("23")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "24") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("24")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "25") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("25")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "26") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("26")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "27") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("27")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "28") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("28")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "29") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("29")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "30") then
                    PlaySoundFile(soundFilePathsDAO[42])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("30")
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetTextColor(1, 0, 0)
                    player1Hand2BetAmountTextDAO:SetTextColor(1, 0, 0)
                elseif string.find(messageDAO, "4") then
                    PlaySoundFile(soundFilePathsDAO[4])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("4")
                elseif string.find(messageDAO, "5") then
                    PlaySoundFile(soundFilePathsDAO[5])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("5")
                elseif string.find(messageDAO, "6") then
                    PlaySoundFile(soundFilePathsDAO[6])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("6")
                elseif string.find(messageDAO, "7") then
                    PlaySoundFile(soundFilePathsDAO[7])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("7")
                elseif string.find(messageDAO, "8") then
                    PlaySoundFile(soundFilePathsDAO[8])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("8")
                elseif string.find(messageDAO, "9") then
                    PlaySoundFile(soundFilePathsDAO[9])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("9")
                elseif string.find(messageDAO, "10") then
                    PlaySoundFile(soundFilePathsDAO[10])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("10")
                elseif string.find(messageDAO, "11") then
                    PlaySoundFile(soundFilePathsDAO[11])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("11")
                elseif string.find(messageDAO, "12") then
                    PlaySoundFile(soundFilePathsDAO[12])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("12")
                elseif string.find(messageDAO, "13") then
                    PlaySoundFile(soundFilePathsDAO[13])
                    dealerFrameDAO.player1SplitHand2CardTotalTextDAO:SetText("13")
                end
            end
        end
    
    elseif turnDAO == 2 then
        if string.find(messageDAO, "1 or 11") then
            PlaySoundFile(soundFilePathsDAO[22])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("1 or 11")
        elseif string.find(messageDAO, "2") then
            PlaySoundFile(soundFilePathsDAO[2])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("2")
        elseif string.find(messageDAO, "3") then
            PlaySoundFile(soundFilePathsDAO[3])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("3")
        elseif string.find(messageDAO, "4") then
            PlaySoundFile(soundFilePathsDAO[4])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
        elseif string.find(messageDAO, "5") then
            PlaySoundFile(soundFilePathsDAO[5])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
        elseif string.find(messageDAO, "6") then
            PlaySoundFile(soundFilePathsDAO[6])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
        elseif string.find(messageDAO, "7") then
            PlaySoundFile(soundFilePathsDAO[7])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
        elseif string.find(messageDAO, "8") then
            PlaySoundFile(soundFilePathsDAO[8])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
        elseif string.find(messageDAO, "9") then
            PlaySoundFile(soundFilePathsDAO[9])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
        elseif string.find(messageDAO, "10") then
            PlaySoundFile(soundFilePathsDAO[10])
            dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
        end

    elseif string.find(messageDAO, "Dealer") and string.find(messageDAO, "has") and not string.find(messageDAO, "turnDAOed") or string.find(messageDAO, "Dealer got") then
        if turnDAO >= 24 then
            
            if string.find(messageDAO, "Blackjack") then
                PlaySoundFile(soundFilePathsDAO[111])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("Blackjack")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 1, 0)
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "2 or 12") then
                PlaySoundFile(soundFilePathsDAO[23])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("2 or 12")
            elseif string.find(messageDAO, "3 or 13") then
                PlaySoundFile(soundFilePathsDAO[24])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("3 or 13")
            elseif string.find(messageDAO, "4 or 14") then
                PlaySoundFile(soundFilePathsDAO[25])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4 or 14")
            elseif string.find(messageDAO, "5 or 15") then
                PlaySoundFile(soundFilePathsDAO[26])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5 or 15")
            elseif string.find(messageDAO, "6 or 16") then
                PlaySoundFile(soundFilePathsDAO[27])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6 or 16")
            elseif string.find(messageDAO, "14") then
                PlaySoundFile(soundFilePathsDAO[14])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("14")
            elseif string.find(messageDAO, "15") then
                PlaySoundFile(soundFilePathsDAO[15])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("15")
            elseif string.find(messageDAO, "16") then
                PlaySoundFile(soundFilePathsDAO[16])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("16")
            elseif string.find(messageDAO, "17") then
                PlaySoundFile(soundFilePathsDAO[17])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("17")
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "18") then
                PlaySoundFile(soundFilePathsDAO[18])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("18")
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "19") then
                PlaySoundFile(soundFilePathsDAO[19])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("19")
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "20") then
                PlaySoundFile(soundFilePathsDAO[20])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("20")
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "21") then
                PlaySoundFile(soundFilePathsDAO[21])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("21")
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "22") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("22")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "23") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("23")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "24") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("24")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "25") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("25")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "26") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("26")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "27") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("27")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "28") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("28")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "29") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("29")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "30") then
                PlaySoundFile(soundFilePathsDAO[112])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("30")
                dealerFrameDAO.dealerCardTotalTextDAO:SetTextColor(1, 0, 0)
                StartResultsTimer1DAO()
            elseif string.find(messageDAO, "4") then
                PlaySoundFile(soundFilePathsDAO[4])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("4")
            elseif string.find(messageDAO, "5") then
                PlaySoundFile(soundFilePathsDAO[5])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("5")
            elseif string.find(messageDAO, "6") then
                PlaySoundFile(soundFilePathsDAO[6])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("6")
            elseif string.find(messageDAO, "7") then
                PlaySoundFile(soundFilePathsDAO[7])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("7")
            elseif string.find(messageDAO, "8") then
                PlaySoundFile(soundFilePathsDAO[8])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("8")
            elseif string.find(messageDAO, "9") then
                PlaySoundFile(soundFilePathsDAO[9])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("9")
            elseif string.find(messageDAO, "10") then
                PlaySoundFile(soundFilePathsDAO[10])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("10")
            elseif string.find(messageDAO, "11") then
                PlaySoundFile(soundFilePathsDAO[11])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("11")
            elseif string.find(messageDAO, "12") then
                PlaySoundFile(soundFilePathsDAO[12])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("12")
            elseif string.find(messageDAO, "13") then
                PlaySoundFile(soundFilePathsDAO[13])
                dealerFrameDAO.dealerCardTotalTextDAO:SetText("13")
            end

        end

    end

end









function SideBets12345DAO()

    -- When it reaches Player 1: 3rd Card
    if turnDAO == 11 then

        -- Set all side bet text amounts to red initially
        player1213AmountTextDAO:SetTextColor(1, 0, 0)
        player1PPAmountTextDAO:SetTextColor(1, 0, 0)
        player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player2213AmountTextDAO:SetTextColor(1, 0, 0)
        player2PPAmountTextDAO:SetTextColor(1, 0, 0)
        player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 1: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 2: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 3: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Player 4: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 1: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")
        -- Player 2: 2nd Card
        cardRank8DAO = string.match(dealtCardsDAO[8], "([%a%d]+)")
        cardSuit8DAO = string.match(dealtCardsDAO[8], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank9DAO = string.match(dealtCardsDAO[9], "([%a%d]+)")
        cardSuit9DAO = string.match(dealtCardsDAO[9], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank10DAO = string.match(dealtCardsDAO[10], "([%a%d]+)")
        cardSuit10DAO = string.match(dealtCardsDAO[10], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank11DAO = string.match(dealtCardsDAO[11], "([%a%d]+)")
        cardSuit11DAO = string.match(dealtCardsDAO[11], "of%s+(%a+)")

        -- Player 1
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit6DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank6DAO and cardRank6DAO == cardRank7DAO then

                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end

                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player1PPSideBetWinDAO == false then

                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank6DAO == "2" and cardRank7DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank6DAO == "3" and cardRank7DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank6DAO == "Ace" and cardRank7DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank6DAO == "3" and cardRank7DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank6DAO == "Ace" and cardRank7DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank6DAO == "2" and cardRank7DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank6DAO == "3" and cardRank7DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank6DAO == "4" and cardRank7DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank6DAO == "4" and cardRank7DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank6DAO == "2" and cardRank7DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank6DAO == "2" and cardRank7DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank6DAO == "3" and cardRank7DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank6DAO == "4" and cardRank7DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank6DAO == "5" and cardRank7DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank6DAO == "5" and cardRank7DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank6DAO == "3" and cardRank7DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank6DAO == "3" and cardRank7DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank6DAO == "4" and cardRank7DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank6DAO == "5" and cardRank7DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank6DAO == "6" and cardRank7DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank6DAO == "6" and cardRank7DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank6DAO == "4" and cardRank7DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank6DAO == "4" and cardRank7DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank6DAO == "5" and cardRank7DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank6DAO == "6" and cardRank7DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank6DAO == "7" and cardRank7DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank6DAO == "7" and cardRank7DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank6DAO == "5" and cardRank7DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank6DAO == "5" and cardRank7DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank6DAO == "6" and cardRank7DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank6DAO == "7" and cardRank7DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank6DAO == "8" and cardRank7DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank6DAO == "8" and cardRank7DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank6DAO == "6" and cardRank7DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank6DAO == "6" and cardRank7DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank6DAO == "7" and cardRank7DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank6DAO == "8" and cardRank7DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank6DAO == "9" and cardRank7DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank6DAO == "9" and cardRank7DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank6DAO == "7" and cardRank7DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank6DAO == "7" and cardRank7DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank6DAO == "8" and cardRank7DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank6DAO == "9" and cardRank7DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank6DAO == "10" and cardRank7DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank6DAO == "10" and cardRank7DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank6DAO == "8" and cardRank7DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank6DAO == "8" and cardRank7DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank6DAO == "9" and cardRank7DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank6DAO == "10" and cardRank7DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank6DAO == "Jack" and cardRank7DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank6DAO == "Jack" and cardRank7DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank6DAO == "9" and cardRank7DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank6DAO == "9" and cardRank7DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank6DAO == "10" and cardRank7DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank6DAO == "Jack" and cardRank7DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank6DAO == "Queen" and cardRank7DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank6DAO == "Queen" and cardRank7DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank6DAO == "10" and cardRank7DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank6DAO == "10" and cardRank7DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank6DAO == "Jack" and cardRank7DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank6DAO == "Queen" and cardRank7DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank6DAO == "King" and cardRank7DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank6DAO == "King" and cardRank7DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank6DAO == "Jack" and cardRank7DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank6DAO == "Jack" and cardRank7DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank6DAO == "Queen" and cardRank7DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank6DAO == "King" and cardRank7DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank6DAO == "Ace" and cardRank7DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank6DAO == "Ace" and cardRank7DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank6DAO == "Queen" and cardRank7DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank6DAO == "Queen" and cardRank7DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank6DAO == "King" and cardRank7DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1FlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank7DAO then

                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    else
                    end
                    
                    if player1PPSideBetWinDAO == false then

                        if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player1PerfectPairWinDAO()
                            SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank6DAO and cardRank6DAO == cardRank7DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank6DAO == "2" and cardRank7DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank6DAO == "3" and cardRank7DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank6DAO == "Ace" and cardRank7DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank6DAO == "3" and cardRank7DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank6DAO == "Ace" and cardRank7DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank6DAO == "2" and cardRank7DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank6DAO == "3" and cardRank7DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank6DAO == "4" and cardRank7DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank6DAO == "4" and cardRank7DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank6DAO == "2" and cardRank7DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank6DAO == "2" and cardRank7DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank6DAO == "3" and cardRank7DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank6DAO == "4" and cardRank7DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank6DAO == "5" and cardRank7DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank6DAO == "5" and cardRank7DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank6DAO == "3" and cardRank7DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank6DAO == "3" and cardRank7DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank6DAO == "4" and cardRank7DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank6DAO == "5" and cardRank7DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank6DAO == "6" and cardRank7DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank6DAO == "6" and cardRank7DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank6DAO == "4" and cardRank7DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank6DAO == "4" and cardRank7DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank6DAO == "5" and cardRank7DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank6DAO == "6" and cardRank7DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank6DAO == "7" and cardRank7DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank6DAO == "7" and cardRank7DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank6DAO == "5" and cardRank7DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank6DAO == "5" and cardRank7DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank6DAO == "6" and cardRank7DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank6DAO == "7" and cardRank7DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank6DAO == "8" and cardRank7DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank6DAO == "8" and cardRank7DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank6DAO == "6" and cardRank7DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank6DAO == "6" and cardRank7DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank6DAO == "7" and cardRank7DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank6DAO == "8" and cardRank7DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank6DAO == "9" and cardRank7DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank6DAO == "9" and cardRank7DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank6DAO == "7" and cardRank7DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank6DAO == "7" and cardRank7DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank6DAO == "8" and cardRank7DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank6DAO == "9" and cardRank7DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank6DAO == "10" and cardRank7DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank6DAO == "10" and cardRank7DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank6DAO == "8" and cardRank7DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank6DAO == "8" and cardRank7DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank6DAO == "9" and cardRank7DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank6DAO == "10" and cardRank7DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank6DAO == "Jack" and cardRank7DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank6DAO == "Jack" and cardRank7DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank6DAO == "9" and cardRank7DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank6DAO == "9" and cardRank7DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank6DAO == "10" and cardRank7DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank6DAO == "Jack" and cardRank7DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank6DAO == "Queen" and cardRank7DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank6DAO == "Queen" and cardRank7DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank6DAO == "10" and cardRank7DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank6DAO == "10" and cardRank7DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank6DAO == "Jack" and cardRank7DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank6DAO == "Queen" and cardRank7DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank6DAO == "King" and cardRank7DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank6DAO == "King" and cardRank7DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank6DAO == "Jack" and cardRank7DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank6DAO == "Jack" and cardRank7DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank6DAO == "Queen" and cardRank7DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank6DAO == "King" and cardRank7DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank6DAO == "Ace" and cardRank7DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank6DAO == "Ace" and cardRank7DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank6DAO == "Queen" and cardRank7DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank6DAO == "Queen" and cardRank7DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank6DAO == "King" and cardRank7DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank7DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 2
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank6DAO and cardRank6DAO == cardRank8DAO then

                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end

                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player2PPSideBetWinDAO == false then

                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank6DAO == "2" and cardRank8DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank6DAO == "3" and cardRank8DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank6DAO == "Ace" and cardRank8DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank6DAO == "3" and cardRank8DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank6DAO == "Ace" and cardRank8DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank6DAO == "2" and cardRank8DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank6DAO == "3" and cardRank8DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank6DAO == "4" and cardRank8DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank6DAO == "4" and cardRank8DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank6DAO == "2" and cardRank8DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank6DAO == "2" and cardRank8DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank6DAO == "3" and cardRank8DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank6DAO == "4" and cardRank8DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank6DAO == "5" and cardRank8DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank6DAO == "5" and cardRank8DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank6DAO == "3" and cardRank8DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank6DAO == "3" and cardRank8DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank6DAO == "4" and cardRank8DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank6DAO == "5" and cardRank8DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank6DAO == "6" and cardRank8DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank6DAO == "6" and cardRank8DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank6DAO == "4" and cardRank8DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank6DAO == "4" and cardRank8DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank6DAO == "5" and cardRank8DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank6DAO == "6" and cardRank8DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank6DAO == "7" and cardRank8DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank6DAO == "7" and cardRank8DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank6DAO == "5" and cardRank8DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank6DAO == "5" and cardRank8DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank6DAO == "6" and cardRank8DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank6DAO == "7" and cardRank8DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank6DAO == "8" and cardRank8DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank6DAO == "8" and cardRank8DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank6DAO == "6" and cardRank8DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank6DAO == "6" and cardRank8DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank6DAO == "7" and cardRank8DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank6DAO == "8" and cardRank8DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank6DAO == "9" and cardRank8DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank6DAO == "9" and cardRank8DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank6DAO == "7" and cardRank8DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank6DAO == "7" and cardRank8DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank6DAO == "8" and cardRank8DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank6DAO == "9" and cardRank8DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank6DAO == "10" and cardRank8DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank6DAO == "10" and cardRank8DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank6DAO == "8" and cardRank8DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank6DAO == "8" and cardRank8DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank6DAO == "9" and cardRank8DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank6DAO == "10" and cardRank8DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank6DAO == "Jack" and cardRank8DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank6DAO == "Jack" and cardRank8DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank6DAO == "9" and cardRank8DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank6DAO == "9" and cardRank8DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank6DAO == "10" and cardRank8DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank6DAO == "Jack" and cardRank8DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank6DAO == "Queen" and cardRank8DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank6DAO == "Queen" and cardRank8DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank6DAO == "10" and cardRank8DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank6DAO == "10" and cardRank8DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank6DAO == "Jack" and cardRank8DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank6DAO == "Queen" and cardRank8DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank6DAO == "King" and cardRank8DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank6DAO == "King" and cardRank8DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank6DAO == "Jack" and cardRank8DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank6DAO == "Jack" and cardRank8DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank6DAO == "Queen" and cardRank8DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank6DAO == "King" and cardRank8DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank6DAO == "Ace" and cardRank8DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank6DAO == "Ace" and cardRank8DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank6DAO == "Queen" and cardRank8DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank6DAO == "Queen" and cardRank8DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank6DAO == "King" and cardRank8DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2FlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank8DAO then

                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    else
                    end
                    
                    if player2PPSideBetWinDAO == false then

                        if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player2PerfectPairWinDAO()
                            SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank6DAO and cardRank6DAO == cardRank8DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank6DAO == "2" and cardRank8DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank6DAO == "3" and cardRank8DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank6DAO == "Ace" and cardRank8DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank6DAO == "3" and cardRank8DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank6DAO == "Ace" and cardRank8DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank6DAO == "2" and cardRank8DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank6DAO == "3" and cardRank8DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank6DAO == "4" and cardRank8DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank6DAO == "4" and cardRank8DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank6DAO == "2" and cardRank8DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank6DAO == "2" and cardRank8DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank6DAO == "3" and cardRank8DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank6DAO == "4" and cardRank8DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank6DAO == "5" and cardRank8DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank6DAO == "5" and cardRank8DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank6DAO == "3" and cardRank8DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank6DAO == "3" and cardRank8DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank6DAO == "4" and cardRank8DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank6DAO == "5" and cardRank8DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank6DAO == "6" and cardRank8DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank6DAO == "6" and cardRank8DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank6DAO == "4" and cardRank8DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank6DAO == "4" and cardRank8DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank6DAO == "5" and cardRank8DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank6DAO == "6" and cardRank8DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank6DAO == "7" and cardRank8DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank6DAO == "7" and cardRank8DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank6DAO == "5" and cardRank8DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank6DAO == "5" and cardRank8DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank6DAO == "6" and cardRank8DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank6DAO == "7" and cardRank8DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank6DAO == "8" and cardRank8DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank6DAO == "8" and cardRank8DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank6DAO == "6" and cardRank8DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank6DAO == "6" and cardRank8DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank6DAO == "7" and cardRank8DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank6DAO == "8" and cardRank8DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank6DAO == "9" and cardRank8DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank6DAO == "9" and cardRank8DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank6DAO == "7" and cardRank8DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank6DAO == "7" and cardRank8DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank6DAO == "8" and cardRank8DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank6DAO == "9" and cardRank8DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank6DAO == "10" and cardRank8DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank6DAO == "10" and cardRank8DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank6DAO == "8" and cardRank8DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank6DAO == "8" and cardRank8DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank6DAO == "9" and cardRank8DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank6DAO == "10" and cardRank8DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank6DAO == "Jack" and cardRank8DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank6DAO == "Jack" and cardRank8DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank6DAO == "9" and cardRank8DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank6DAO == "9" and cardRank8DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank6DAO == "10" and cardRank8DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank6DAO == "Jack" and cardRank8DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank6DAO == "Queen" and cardRank8DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank6DAO == "Queen" and cardRank8DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank6DAO == "10" and cardRank8DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank6DAO == "10" and cardRank8DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank6DAO == "Jack" and cardRank8DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank6DAO == "Queen" and cardRank8DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank6DAO == "King" and cardRank8DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank6DAO == "King" and cardRank8DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank6DAO == "Jack" and cardRank8DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank6DAO == "Jack" and cardRank8DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank6DAO == "Queen" and cardRank8DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank6DAO == "King" and cardRank8DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank6DAO == "Ace" and cardRank8DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank6DAO == "Ace" and cardRank8DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank6DAO == "Queen" and cardRank8DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank6DAO == "Queen" and cardRank8DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank6DAO == "King" and cardRank8DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank8DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit6DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit6DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit6DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit6DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank6DAO and cardRank6DAO == cardRank9DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank6DAO == "2" and cardRank9DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank6DAO == "3" and cardRank9DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank6DAO == "Ace" and cardRank9DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank6DAO == "3" and cardRank9DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank6DAO == "Ace" and cardRank9DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank6DAO == "2" and cardRank9DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank6DAO == "3" and cardRank9DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank6DAO == "4" and cardRank9DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank6DAO == "4" and cardRank9DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank6DAO == "2" and cardRank9DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank6DAO == "2" and cardRank9DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank6DAO == "3" and cardRank9DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank6DAO == "4" and cardRank9DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank6DAO == "5" and cardRank9DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank6DAO == "5" and cardRank9DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank6DAO == "3" and cardRank9DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank6DAO == "3" and cardRank9DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank6DAO == "4" and cardRank9DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank6DAO == "5" and cardRank9DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank6DAO == "6" and cardRank9DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank6DAO == "6" and cardRank9DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank6DAO == "4" and cardRank9DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank6DAO == "4" and cardRank9DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank6DAO == "5" and cardRank9DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank6DAO == "6" and cardRank9DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank6DAO == "7" and cardRank9DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank6DAO == "7" and cardRank9DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank6DAO == "5" and cardRank9DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank6DAO == "5" and cardRank9DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank6DAO == "6" and cardRank9DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank6DAO == "7" and cardRank9DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank6DAO == "8" and cardRank9DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank6DAO == "8" and cardRank9DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank6DAO == "6" and cardRank9DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank6DAO == "6" and cardRank9DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank6DAO == "7" and cardRank9DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank6DAO == "8" and cardRank9DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank6DAO == "9" and cardRank9DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank6DAO == "9" and cardRank9DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank6DAO == "7" and cardRank9DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank6DAO == "7" and cardRank9DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank6DAO == "8" and cardRank9DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank6DAO == "9" and cardRank9DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank6DAO == "10" and cardRank9DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank6DAO == "10" and cardRank9DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank6DAO == "8" and cardRank9DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank6DAO == "8" and cardRank9DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank6DAO == "9" and cardRank9DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank6DAO == "10" and cardRank9DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank6DAO == "Jack" and cardRank9DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank6DAO == "Jack" and cardRank9DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank6DAO == "9" and cardRank9DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank6DAO == "9" and cardRank9DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank6DAO == "10" and cardRank9DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank6DAO == "Jack" and cardRank9DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank6DAO == "Queen" and cardRank9DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank6DAO == "Queen" and cardRank9DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank6DAO == "10" and cardRank9DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank6DAO == "10" and cardRank9DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank6DAO == "Jack" and cardRank9DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank6DAO == "Queen" and cardRank9DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank6DAO == "King" and cardRank9DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank6DAO == "King" and cardRank9DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank6DAO == "Jack" and cardRank9DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank6DAO == "Jack" and cardRank9DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank6DAO == "Queen" and cardRank9DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank6DAO == "King" and cardRank9DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank6DAO == "Ace" and cardRank9DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank6DAO == "Ace" and cardRank9DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank6DAO == "Queen" and cardRank9DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank6DAO == "Queen" and cardRank9DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank6DAO == "King" and cardRank9DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank9DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank6DAO and cardRank6DAO == cardRank9DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank6DAO == "2" and cardRank9DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank6DAO == "3" and cardRank9DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank6DAO == "Ace" and cardRank9DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank6DAO == "3" and cardRank9DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank6DAO == "Ace" and cardRank9DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank6DAO == "2" and cardRank9DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank6DAO == "3" and cardRank9DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank6DAO == "4" and cardRank9DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank6DAO == "4" and cardRank9DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank6DAO == "2" and cardRank9DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank6DAO == "2" and cardRank9DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank6DAO == "3" and cardRank9DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank6DAO == "4" and cardRank9DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank6DAO == "5" and cardRank9DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank6DAO == "5" and cardRank9DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank6DAO == "3" and cardRank9DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank6DAO == "3" and cardRank9DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank6DAO == "4" and cardRank9DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank6DAO == "5" and cardRank9DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank6DAO == "6" and cardRank9DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank6DAO == "6" and cardRank9DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank6DAO == "4" and cardRank9DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank6DAO == "4" and cardRank9DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank6DAO == "5" and cardRank9DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank6DAO == "6" and cardRank9DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank6DAO == "7" and cardRank9DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank6DAO == "7" and cardRank9DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank6DAO == "5" and cardRank9DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank6DAO == "5" and cardRank9DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank6DAO == "6" and cardRank9DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank6DAO == "7" and cardRank9DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank6DAO == "8" and cardRank9DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank6DAO == "8" and cardRank9DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank6DAO == "6" and cardRank9DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank6DAO == "6" and cardRank9DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank6DAO == "7" and cardRank9DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank6DAO == "8" and cardRank9DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank6DAO == "9" and cardRank9DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank6DAO == "9" and cardRank9DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank6DAO == "7" and cardRank9DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank6DAO == "7" and cardRank9DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank6DAO == "8" and cardRank9DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank6DAO == "9" and cardRank9DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank6DAO == "10" and cardRank9DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank6DAO == "10" and cardRank9DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank6DAO == "8" and cardRank9DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank6DAO == "8" and cardRank9DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank6DAO == "9" and cardRank9DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank6DAO == "10" and cardRank9DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank6DAO == "Jack" and cardRank9DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank6DAO == "Jack" and cardRank9DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank6DAO == "9" and cardRank9DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank6DAO == "9" and cardRank9DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank6DAO == "10" and cardRank9DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank6DAO == "Jack" and cardRank9DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank6DAO == "Queen" and cardRank9DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank6DAO == "Queen" and cardRank9DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank6DAO == "10" and cardRank9DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank6DAO == "10" and cardRank9DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank6DAO == "Jack" and cardRank9DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank6DAO == "Queen" and cardRank9DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank6DAO == "King" and cardRank9DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank6DAO == "King" and cardRank9DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank6DAO == "Jack" and cardRank9DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank6DAO == "Jack" and cardRank9DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank6DAO == "Queen" and cardRank9DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank6DAO == "King" and cardRank9DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank6DAO == "Ace" and cardRank9DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank6DAO == "Ace" and cardRank9DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank6DAO == "Queen" and cardRank9DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank6DAO == "Queen" and cardRank9DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank6DAO == "King" and cardRank9DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank9DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit4DAO == "Spades" and cardSuit6DAO == "Spades" and cardSuit10DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit6DAO == "Clubs" and cardSuit10DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit6DAO == "Hearts" and cardSuit10DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit6DAO == "Diamonds" and cardSuit10DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank4DAO == cardRank6DAO and cardRank6DAO == cardRank10DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank4DAO == "Ace" and cardRank6DAO == "2" and cardRank10DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank6DAO == "3" and cardRank10DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank6DAO == "Ace" and cardRank10DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank6DAO == "3" and cardRank10DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank6DAO == "Ace" and cardRank10DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank6DAO == "2" and cardRank10DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank6DAO == "3" and cardRank10DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank6DAO == "4" and cardRank10DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank6DAO == "4" and cardRank10DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank6DAO == "2" and cardRank10DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank6DAO == "2" and cardRank10DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank6DAO == "3" and cardRank10DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank6DAO == "4" and cardRank10DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank6DAO == "5" and cardRank10DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank6DAO == "5" and cardRank10DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank6DAO == "3" and cardRank10DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank6DAO == "3" and cardRank10DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank6DAO == "4" and cardRank10DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank6DAO == "5" and cardRank10DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank6DAO == "6" and cardRank10DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank6DAO == "6" and cardRank10DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank6DAO == "4" and cardRank10DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank6DAO == "4" and cardRank10DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank6DAO == "5" and cardRank10DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank6DAO == "6" and cardRank10DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank6DAO == "7" and cardRank10DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank6DAO == "7" and cardRank10DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank6DAO == "5" and cardRank10DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank6DAO == "5" and cardRank10DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank6DAO == "6" and cardRank10DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank6DAO == "7" and cardRank10DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank6DAO == "8" and cardRank10DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank6DAO == "8" and cardRank10DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank6DAO == "6" and cardRank10DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank6DAO == "6" and cardRank10DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank6DAO == "7" and cardRank10DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank6DAO == "8" and cardRank10DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank6DAO == "9" and cardRank10DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank6DAO == "9" and cardRank10DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank6DAO == "7" and cardRank10DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank6DAO == "7" and cardRank10DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank6DAO == "8" and cardRank10DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank6DAO == "9" and cardRank10DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank6DAO == "10" and cardRank10DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank6DAO == "10" and cardRank10DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank6DAO == "8" and cardRank10DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank6DAO == "8" and cardRank10DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank6DAO == "9" and cardRank10DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank6DAO == "10" and cardRank10DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank6DAO == "Jack" and cardRank10DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank6DAO == "Jack" and cardRank10DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank6DAO == "9" and cardRank10DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank6DAO == "9" and cardRank10DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank6DAO == "10" and cardRank10DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank6DAO == "Jack" and cardRank10DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank6DAO == "Queen" and cardRank10DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank6DAO == "Queen" and cardRank10DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank6DAO == "10" and cardRank10DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank6DAO == "10" and cardRank10DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank6DAO == "Jack" and cardRank10DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank6DAO == "Queen" and cardRank10DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank6DAO == "King" and cardRank10DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank6DAO == "King" and cardRank10DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank6DAO == "Jack" and cardRank10DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank6DAO == "Jack" and cardRank10DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank6DAO == "Queen" and cardRank10DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank6DAO == "King" and cardRank10DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank6DAO == "Ace" and cardRank10DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank6DAO == "Ace" and cardRank10DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank6DAO == "Queen" and cardRank10DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank6DAO == "Queen" and cardRank10DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank6DAO == "King" and cardRank10DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank4DAO == cardRank10DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank4DAO == cardRank6DAO and cardRank6DAO == cardRank10DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit10DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit10DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit10DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit10DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit10DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit10DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit10DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit10DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank4DAO == "Ace" and cardRank6DAO == "2" and cardRank10DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank6DAO == "3" and cardRank10DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank6DAO == "Ace" and cardRank10DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank6DAO == "3" and cardRank10DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank6DAO == "Ace" and cardRank10DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank6DAO == "2" and cardRank10DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank6DAO == "3" and cardRank10DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank6DAO == "4" and cardRank10DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank6DAO == "4" and cardRank10DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank6DAO == "2" and cardRank10DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank6DAO == "2" and cardRank10DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank6DAO == "3" and cardRank10DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank6DAO == "4" and cardRank10DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank6DAO == "5" and cardRank10DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank6DAO == "5" and cardRank10DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank6DAO == "3" and cardRank10DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank6DAO == "3" and cardRank10DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank6DAO == "4" and cardRank10DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank6DAO == "5" and cardRank10DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank6DAO == "6" and cardRank10DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank6DAO == "6" and cardRank10DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank6DAO == "4" and cardRank10DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank6DAO == "4" and cardRank10DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank6DAO == "5" and cardRank10DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank6DAO == "6" and cardRank10DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank6DAO == "7" and cardRank10DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank6DAO == "7" and cardRank10DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank6DAO == "5" and cardRank10DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank6DAO == "5" and cardRank10DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank6DAO == "6" and cardRank10DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank6DAO == "7" and cardRank10DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank6DAO == "8" and cardRank10DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank6DAO == "8" and cardRank10DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank6DAO == "6" and cardRank10DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank6DAO == "6" and cardRank10DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank6DAO == "7" and cardRank10DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank6DAO == "8" and cardRank10DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank6DAO == "9" and cardRank10DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank6DAO == "9" and cardRank10DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank6DAO == "7" and cardRank10DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank6DAO == "7" and cardRank10DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank6DAO == "8" and cardRank10DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank6DAO == "9" and cardRank10DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank6DAO == "10" and cardRank10DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank6DAO == "10" and cardRank10DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank6DAO == "8" and cardRank10DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank6DAO == "8" and cardRank10DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank6DAO == "9" and cardRank10DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank6DAO == "10" and cardRank10DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank6DAO == "Jack" and cardRank10DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank6DAO == "Jack" and cardRank10DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank6DAO == "9" and cardRank10DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank6DAO == "9" and cardRank10DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank6DAO == "10" and cardRank10DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank6DAO == "Jack" and cardRank10DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank6DAO == "Queen" and cardRank10DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank6DAO == "Queen" and cardRank10DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank6DAO == "10" and cardRank10DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank6DAO == "10" and cardRank10DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank6DAO == "Jack" and cardRank10DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank6DAO == "Queen" and cardRank10DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank6DAO == "King" and cardRank10DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank6DAO == "King" and cardRank10DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank6DAO == "Jack" and cardRank10DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank6DAO == "Jack" and cardRank10DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank6DAO == "Queen" and cardRank10DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank6DAO == "King" and cardRank10DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank6DAO == "Ace" and cardRank10DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank6DAO == "Ace" and cardRank10DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank6DAO == "Queen" and cardRank10DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank6DAO == "Queen" and cardRank10DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank6DAO == "King" and cardRank10DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank4DAO == cardRank10DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit10DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit10DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit10DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit10DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit10DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit10DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit10DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit10DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit5DAO == "Spades" and cardSuit6DAO == "Spades" and cardSuit11DAO == "Spades" or cardSuit5DAO == "Clubs" and cardSuit6DAO == "Clubs" and cardSuit11DAO == "Clubs" or cardSuit5DAO == "Hearts" and cardSuit6DAO == "Hearts" and cardSuit11DAO == "Hearts" or cardSuit5DAO == "Diamonds" and cardSuit6DAO == "Diamonds" and cardSuit11DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank5DAO == cardRank6DAO and cardRank6DAO == cardRank11DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank5DAO == "Ace" and cardRank6DAO == "2" and cardRank11DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Ace" and cardRank6DAO == "3" and cardRank11DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "2" and cardRank6DAO == "Ace" and cardRank11DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "2" and cardRank6DAO == "3" and cardRank11DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "3" and cardRank6DAO == "Ace" and cardRank11DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "3" and cardRank6DAO == "2" and cardRank11DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "2" and cardRank6DAO == "3" and cardRank11DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "2" and cardRank6DAO == "4" and cardRank11DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "3" and cardRank6DAO == "4" and cardRank11DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "3" and cardRank6DAO == "2" and cardRank11DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "4" and cardRank6DAO == "2" and cardRank11DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "4" and cardRank6DAO == "3" and cardRank11DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "3" and cardRank6DAO == "4" and cardRank11DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "3" and cardRank6DAO == "5" and cardRank11DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "4" and cardRank6DAO == "5" and cardRank11DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "4" and cardRank6DAO == "3" and cardRank11DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "5" and cardRank6DAO == "3" and cardRank11DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "5" and cardRank6DAO == "4" and cardRank11DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "4" and cardRank6DAO == "5" and cardRank11DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "4" and cardRank6DAO == "6" and cardRank11DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "5" and cardRank6DAO == "6" and cardRank11DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "5" and cardRank6DAO == "4" and cardRank11DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "6" and cardRank6DAO == "4" and cardRank11DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "6" and cardRank6DAO == "5" and cardRank11DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "5" and cardRank6DAO == "6" and cardRank11DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "5" and cardRank6DAO == "7" and cardRank11DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "6" and cardRank6DAO == "7" and cardRank11DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "6" and cardRank6DAO == "5" and cardRank11DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "7" and cardRank6DAO == "5" and cardRank11DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "7" and cardRank6DAO == "6" and cardRank11DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "6" and cardRank6DAO == "7" and cardRank11DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "6" and cardRank6DAO == "8" and cardRank11DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "7" and cardRank6DAO == "8" and cardRank11DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "7" and cardRank6DAO == "6" and cardRank11DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "8" and cardRank6DAO == "6" and cardRank11DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "8" and cardRank6DAO == "7" and cardRank11DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "7" and cardRank6DAO == "8" and cardRank11DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "7" and cardRank6DAO == "9" and cardRank11DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "8" and cardRank6DAO == "9" and cardRank11DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "8" and cardRank6DAO == "7" and cardRank11DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "9" and cardRank6DAO == "7" and cardRank11DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "9" and cardRank6DAO == "8" and cardRank11DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "8" and cardRank6DAO == "9" and cardRank11DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "8" and cardRank6DAO == "10" and cardRank11DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "9" and cardRank6DAO == "10" and cardRank11DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "9" and cardRank6DAO == "8" and cardRank11DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "10" and cardRank6DAO == "8" and cardRank11DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "10" and cardRank6DAO == "9" and cardRank11DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "9" and cardRank6DAO == "10" and cardRank11DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "9" and cardRank6DAO == "Jack" and cardRank11DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "10" and cardRank6DAO == "Jack" and cardRank11DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "10" and cardRank6DAO == "9" and cardRank11DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Jack" and cardRank6DAO == "9" and cardRank11DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Jack" and cardRank6DAO == "10" and cardRank11DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "10" and cardRank6DAO == "Jack" and cardRank11DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "10" and cardRank6DAO == "Queen" and cardRank11DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Jack" and cardRank6DAO == "Queen" and cardRank11DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Jack" and cardRank6DAO == "10" and cardRank11DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Queen" and cardRank6DAO == "10" and cardRank11DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Queen" and cardRank6DAO == "Jack" and cardRank11DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Jack" and cardRank6DAO == "Queen" and cardRank11DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Jack" and cardRank6DAO == "King" and cardRank11DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Queen" and cardRank6DAO == "King" and cardRank11DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Queen" and cardRank6DAO == "Jack" and cardRank11DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "King" and cardRank6DAO == "Jack" and cardRank11DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "King" and cardRank6DAO == "Queen" and cardRank11DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Queen" and cardRank6DAO == "King" and cardRank11DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Queen" and cardRank6DAO == "Ace" and cardRank11DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "King" and cardRank6DAO == "Ace" and cardRank11DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "King" and cardRank6DAO == "Queen" and cardRank11DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Ace" and cardRank6DAO == "Queen" and cardRank11DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank5DAO == "Ace" and cardRank6DAO == "King" and cardRank11DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank5DAO == cardRank11DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank5DAO == cardRank6DAO and cardRank6DAO == cardRank11DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit5DAO == "Spades" and cardSuit11DAO == "Spades" or cardSuit5DAO == "Clubs" and cardSuit11DAO == "Clubs" or cardSuit5DAO == "Hearts" and cardSuit11DAO == "Hearts" or cardSuit5DAO == "Diamonds" and cardSuit11DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit5DAO == "Spades" and cardSuit11DAO == "Clubs" or cardSuit5DAO == "Clubs" and cardSuit11DAO == "Spades" or cardSuit5DAO == "Hearts" and cardSuit11DAO == "Diamonds" or cardSuit5DAO == "Diamonds" and cardSuit11DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank5DAO == "Ace" and cardRank6DAO == "2" and cardRank11DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Ace" and cardRank6DAO == "3" and cardRank11DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "2" and cardRank6DAO == "Ace" and cardRank11DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "2" and cardRank6DAO == "3" and cardRank11DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "3" and cardRank6DAO == "Ace" and cardRank11DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "3" and cardRank6DAO == "2" and cardRank11DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "2" and cardRank6DAO == "3" and cardRank11DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "2" and cardRank6DAO == "4" and cardRank11DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "3" and cardRank6DAO == "4" and cardRank11DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "3" and cardRank6DAO == "2" and cardRank11DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "4" and cardRank6DAO == "2" and cardRank11DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "4" and cardRank6DAO == "3" and cardRank11DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "3" and cardRank6DAO == "4" and cardRank11DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "3" and cardRank6DAO == "5" and cardRank11DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "4" and cardRank6DAO == "5" and cardRank11DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "4" and cardRank6DAO == "3" and cardRank11DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "5" and cardRank6DAO == "3" and cardRank11DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "5" and cardRank6DAO == "4" and cardRank11DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "4" and cardRank6DAO == "5" and cardRank11DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "4" and cardRank6DAO == "6" and cardRank11DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "5" and cardRank6DAO == "6" and cardRank11DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "5" and cardRank6DAO == "4" and cardRank11DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "6" and cardRank6DAO == "4" and cardRank11DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "6" and cardRank6DAO == "5" and cardRank11DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "5" and cardRank6DAO == "6" and cardRank11DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "5" and cardRank6DAO == "7" and cardRank11DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "6" and cardRank6DAO == "7" and cardRank11DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "6" and cardRank6DAO == "5" and cardRank11DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "7" and cardRank6DAO == "5" and cardRank11DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "7" and cardRank6DAO == "6" and cardRank11DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "6" and cardRank6DAO == "7" and cardRank11DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "6" and cardRank6DAO == "8" and cardRank11DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "7" and cardRank6DAO == "8" and cardRank11DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "7" and cardRank6DAO == "6" and cardRank11DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "8" and cardRank6DAO == "6" and cardRank11DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "8" and cardRank6DAO == "7" and cardRank11DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "7" and cardRank6DAO == "8" and cardRank11DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "7" and cardRank6DAO == "9" and cardRank11DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "8" and cardRank6DAO == "9" and cardRank11DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "8" and cardRank6DAO == "7" and cardRank11DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "9" and cardRank6DAO == "7" and cardRank11DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "9" and cardRank6DAO == "8" and cardRank11DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "8" and cardRank6DAO == "9" and cardRank11DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "8" and cardRank6DAO == "10" and cardRank11DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "9" and cardRank6DAO == "10" and cardRank11DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "9" and cardRank6DAO == "8" and cardRank11DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "10" and cardRank6DAO == "8" and cardRank11DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "10" and cardRank6DAO == "9" and cardRank11DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "9" and cardRank6DAO == "10" and cardRank11DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "9" and cardRank6DAO == "Jack" and cardRank11DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "10" and cardRank6DAO == "Jack" and cardRank11DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "10" and cardRank6DAO == "9" and cardRank11DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Jack" and cardRank6DAO == "9" and cardRank11DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Jack" and cardRank6DAO == "10" and cardRank11DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "10" and cardRank6DAO == "Jack" and cardRank11DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "10" and cardRank6DAO == "Queen" and cardRank11DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Jack" and cardRank6DAO == "Queen" and cardRank11DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Jack" and cardRank6DAO == "10" and cardRank11DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Queen" and cardRank6DAO == "10" and cardRank11DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Queen" and cardRank6DAO == "Jack" and cardRank11DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Jack" and cardRank6DAO == "Queen" and cardRank11DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Jack" and cardRank6DAO == "King" and cardRank11DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Queen" and cardRank6DAO == "King" and cardRank11DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Queen" and cardRank6DAO == "Jack" and cardRank11DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "King" and cardRank6DAO == "Jack" and cardRank11DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "King" and cardRank6DAO == "Queen" and cardRank11DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Queen" and cardRank6DAO == "King" and cardRank11DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Queen" and cardRank6DAO == "Ace" and cardRank11DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "King" and cardRank6DAO == "Ace" and cardRank11DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "King" and cardRank6DAO == "Queen" and cardRank11DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Ace" and cardRank6DAO == "Queen" and cardRank11DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank5DAO == "Ace" and cardRank6DAO == "King" and cardRank11DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank5DAO == cardRank11DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit5DAO == "Spades" and cardSuit11DAO == "Spades" or cardSuit5DAO == "Clubs" and cardSuit11DAO == "Clubs" or cardSuit5DAO == "Hearts" and cardSuit11DAO == "Hearts" or cardSuit5DAO == "Diamonds" and cardSuit11DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit5DAO == "Spades" and cardSuit11DAO == "Clubs" or cardSuit5DAO == "Clubs" and cardSuit11DAO == "Spades" or cardSuit5DAO == "Hearts" and cardSuit11DAO == "Diamonds" or cardSuit5DAO == "Diamonds" and cardSuit11DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets2345DAO()

    -- When it reaches Player 2: 3rd Card
    if turnDAO == 9 then

        -- Set all side bet text amounts to red initially
        player2213AmountTextDAO:SetTextColor(1, 0, 0)
        player2PPAmountTextDAO:SetTextColor(1, 0, 0)
        player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 2: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 3: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 4: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 2: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank8DAO = string.match(dealtCardsDAO[8], "([%a%d]+)")
        cardSuit8DAO = string.match(dealtCardsDAO[8], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank9DAO = string.match(dealtCardsDAO[9], "([%a%d]+)")
        cardSuit9DAO = string.match(dealtCardsDAO[9], "of%s+(%a+)")

        -- Player 2
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank5DAO and cardRank5DAO == cardRank6DAO then

                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end

                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player2PPSideBetWinDAO == false then

                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "2" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "3" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "Ace" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "Ace" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "4" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "2" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "5" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "3" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "6" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "4" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "7" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "5" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "8" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "6" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "9" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "7" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "10" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "8" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "9" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Ace" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Ace" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2FlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank6DAO then

                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    else
                    end
                    
                    if player2PPSideBetWinDAO == false then

                        if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player2PerfectPairWinDAO()
                            SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank5DAO and cardRank5DAO == cardRank6DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "2" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "3" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "Ace" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "Ace" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "4" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "2" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "5" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "3" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "6" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "4" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "7" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "5" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "8" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "6" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "9" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "7" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "10" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "8" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "9" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Ace" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Ace" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank6DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank5DAO and cardRank5DAO == cardRank7DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "2" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "3" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "Ace" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "Ace" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "4" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "2" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "5" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "3" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "6" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "4" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "7" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "5" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "8" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "6" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "9" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "7" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "10" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "8" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "9" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Ace" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Ace" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank7DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank5DAO and cardRank5DAO == cardRank7DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "2" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "3" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "Ace" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "Ace" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "4" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "2" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "5" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "3" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "6" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "4" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "7" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "5" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "8" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "6" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "9" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "7" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "10" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "8" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "9" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Ace" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Ace" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank7DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank5DAO and cardRank5DAO == cardRank8DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "2" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "3" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "Ace" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "Ace" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "4" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "2" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "5" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "3" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "6" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "4" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "7" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "5" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "8" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "6" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "9" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "7" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "10" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "8" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "9" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Ace" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Ace" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank8DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank5DAO and cardRank5DAO == cardRank8DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "2" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "3" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "Ace" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "Ace" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "4" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "2" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "5" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "3" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "6" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "4" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "7" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "5" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "8" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "6" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "9" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "7" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "10" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "8" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "9" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Ace" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Ace" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank8DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank4DAO == cardRank5DAO and cardRank5DAO == cardRank9DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "2" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "3" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "Ace" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "Ace" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "4" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "2" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "5" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "3" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "6" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "4" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "7" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "5" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "8" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "6" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "9" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "7" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "10" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "8" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "9" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Ace" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Ace" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank4DAO == cardRank9DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank4DAO == cardRank5DAO and cardRank5DAO == cardRank9DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "2" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "3" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "Ace" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "Ace" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "4" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "2" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "5" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "3" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "6" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "4" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "7" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "5" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "8" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "6" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "9" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "7" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "10" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "8" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "9" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Ace" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Ace" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank4DAO == cardRank9DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets1345DAO()

    -- When it reaches Player 1: 3rd Card
    if turnDAO == 9 then

        -- Set all side bet text amounts to red initially
        player1213AmountTextDAO:SetTextColor(1, 0, 0)
        player1PPAmountTextDAO:SetTextColor(1, 0, 0)
        player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 1: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 3: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 4: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 1: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank8DAO = string.match(dealtCardsDAO[8], "([%a%d]+)")
        cardSuit8DAO = string.match(dealtCardsDAO[8], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank9DAO = string.match(dealtCardsDAO[9], "([%a%d]+)")
        cardSuit9DAO = string.match(dealtCardsDAO[9], "of%s+(%a+)")

        -- Player 1
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank5DAO and cardRank5DAO == cardRank6DAO then

                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end

                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player1PPSideBetWinDAO == false then

                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "2" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "3" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "Ace" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "Ace" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "4" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "2" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "5" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "3" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "6" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "4" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "7" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "5" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "8" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "6" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "9" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "7" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "10" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "8" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "9" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Ace" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Ace" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1FlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank6DAO then

                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    else
                    end
                    
                    if player1PPSideBetWinDAO == false then

                        if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player1PerfectPairWinDAO()
                            SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank5DAO and cardRank5DAO == cardRank6DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "2" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "3" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "Ace" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "Ace" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "4" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "2" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "5" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "3" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "6" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "4" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "7" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "5" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "8" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "6" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "9" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "7" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "10" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "8" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "9" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Ace" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Ace" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank6DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank5DAO and cardRank5DAO == cardRank7DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "2" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "3" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "Ace" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "Ace" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "4" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "2" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "5" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "3" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "6" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "4" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "7" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "5" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "8" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "6" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "9" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "7" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "10" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "8" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "9" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Ace" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Ace" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank7DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank5DAO and cardRank5DAO == cardRank7DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "2" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "3" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "Ace" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "Ace" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "4" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "2" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "5" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "3" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "6" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "4" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "7" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "5" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "8" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "6" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "9" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "7" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "10" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "8" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "9" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Ace" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Ace" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank7DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank5DAO and cardRank5DAO == cardRank8DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "2" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "3" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "Ace" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "Ace" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "4" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "2" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "5" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "3" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "6" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "4" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "7" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "5" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "8" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "6" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "9" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "7" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "10" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "8" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "9" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Ace" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Ace" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank8DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank5DAO and cardRank5DAO == cardRank8DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "2" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "3" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "Ace" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "Ace" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "4" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "2" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "5" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "3" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "6" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "4" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "7" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "5" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "8" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "6" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "9" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "7" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "10" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "8" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "9" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Ace" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Ace" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank8DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank4DAO == cardRank5DAO and cardRank5DAO == cardRank9DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "2" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "3" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "Ace" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "Ace" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "4" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "2" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "5" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "3" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "6" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "4" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "7" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "5" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "8" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "6" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "9" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "7" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "10" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "8" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "9" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Ace" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Ace" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank4DAO == cardRank9DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank4DAO == cardRank5DAO and cardRank5DAO == cardRank9DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "2" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "3" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "Ace" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "Ace" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "4" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "2" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "5" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "3" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "6" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "4" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "7" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "5" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "8" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "6" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "9" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "7" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "10" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "8" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "9" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Ace" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Ace" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank4DAO == cardRank9DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets1245DAO()

    -- When it reaches Player 1: 3rd Card
    if turnDAO == 9 then

        -- Set all side bet text amounts to red initially
        player1213AmountTextDAO:SetTextColor(1, 0, 0)
        player1PPAmountTextDAO:SetTextColor(1, 0, 0)
        player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player2213AmountTextDAO:SetTextColor(1, 0, 0)
        player2PPAmountTextDAO:SetTextColor(1, 0, 0)
        player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 1: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 2: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 4: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 1: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 2: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank8DAO = string.match(dealtCardsDAO[8], "([%a%d]+)")
        cardSuit8DAO = string.match(dealtCardsDAO[8], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank9DAO = string.match(dealtCardsDAO[9], "([%a%d]+)")
        cardSuit9DAO = string.match(dealtCardsDAO[9], "of%s+(%a+)")

        -- Player 1
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank5DAO and cardRank5DAO == cardRank6DAO then

                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end

                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player1PPSideBetWinDAO == false then

                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "2" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "3" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "Ace" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "Ace" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "4" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "2" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "5" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "3" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "6" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "4" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "7" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "5" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "8" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "6" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "9" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "7" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "10" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "8" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "9" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Ace" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Ace" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1FlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank6DAO then

                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    else
                    end
                    
                    if player1PPSideBetWinDAO == false then

                        if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player1PerfectPairWinDAO()
                            SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank5DAO and cardRank5DAO == cardRank6DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "2" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "3" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "Ace" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "Ace" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "4" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "2" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "5" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "3" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "6" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "4" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "7" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "5" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "8" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "6" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "9" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "7" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "10" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "8" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "9" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Ace" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Ace" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank6DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 2
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank5DAO and cardRank5DAO == cardRank7DAO then

                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end

                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player2PPSideBetWinDAO == false then

                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "2" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "3" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "Ace" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "Ace" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "4" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "2" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "5" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "3" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "6" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "4" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "7" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "5" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "8" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "6" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "9" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "7" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "10" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "8" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "9" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Ace" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Ace" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2FlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank7DAO then

                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    else
                    end
                    
                    if player2PPSideBetWinDAO == false then

                        if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player2PerfectPairWinDAO()
                            SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank5DAO and cardRank5DAO == cardRank7DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "2" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "3" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "Ace" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "Ace" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "4" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "2" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "5" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "3" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "6" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "4" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "7" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "5" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "8" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "6" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "9" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "7" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "10" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "8" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "9" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Ace" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Ace" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank7DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank5DAO and cardRank5DAO == cardRank8DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "2" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "3" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "Ace" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "Ace" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "4" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "2" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "5" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "3" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "6" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "4" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "7" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "5" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "8" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "6" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "9" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "7" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "10" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "8" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "9" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Ace" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Ace" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank8DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank5DAO and cardRank5DAO == cardRank8DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "2" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "3" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "Ace" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "Ace" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "4" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "2" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "5" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "3" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "6" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "4" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "7" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "5" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "8" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "6" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "9" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "7" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "10" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "8" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "9" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Ace" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Ace" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank8DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank4DAO == cardRank5DAO and cardRank5DAO == cardRank9DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "2" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "3" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "Ace" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "Ace" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "4" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "2" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "5" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "3" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "6" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "4" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "7" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "5" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "8" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "6" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "9" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "7" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "10" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "8" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "9" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Ace" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Ace" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank4DAO == cardRank9DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank4DAO == cardRank5DAO and cardRank5DAO == cardRank9DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "2" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "3" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "Ace" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "Ace" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "4" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "2" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "5" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "3" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "6" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "4" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "7" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "5" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "8" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "6" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "9" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "7" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "10" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "8" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "9" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Ace" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Ace" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank4DAO == cardRank9DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets1235DAO()

    -- When it reaches Player 1: 3rd Card
    if turnDAO == 9 then

        -- Set all side bet text amounts to red initially
        player1213AmountTextDAO:SetTextColor(1, 0, 0)
        player1PPAmountTextDAO:SetTextColor(1, 0, 0)
        player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player2213AmountTextDAO:SetTextColor(1, 0, 0)
        player2PPAmountTextDAO:SetTextColor(1, 0, 0)
        player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 1: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 2: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 3: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 1: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 2: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank8DAO = string.match(dealtCardsDAO[8], "([%a%d]+)")
        cardSuit8DAO = string.match(dealtCardsDAO[8], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank9DAO = string.match(dealtCardsDAO[9], "([%a%d]+)")
        cardSuit9DAO = string.match(dealtCardsDAO[9], "of%s+(%a+)")

        -- Player 1
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank5DAO and cardRank5DAO == cardRank6DAO then

                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end

                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player1PPSideBetWinDAO == false then

                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "2" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "3" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "Ace" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "Ace" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "4" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "2" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "5" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "3" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "6" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "4" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "7" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "5" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "8" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "6" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "9" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "7" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "10" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "8" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "9" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Ace" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Ace" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1FlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank6DAO then

                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    else
                    end
                    
                    if player1PPSideBetWinDAO == false then

                        if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player1PerfectPairWinDAO()
                            SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank5DAO and cardRank5DAO == cardRank6DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "2" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "3" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "Ace" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "Ace" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "4" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "2" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "5" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "3" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "6" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "4" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "7" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "5" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "8" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "6" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "9" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "7" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "10" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "8" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "9" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Ace" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Ace" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank6DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 2
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank5DAO and cardRank5DAO == cardRank7DAO then

                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end

                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player2PPSideBetWinDAO == false then

                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "2" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "3" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "Ace" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "Ace" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "4" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "2" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "5" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "3" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "6" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "4" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "7" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "5" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "8" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "6" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "9" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "7" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "10" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "8" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "9" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Ace" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Ace" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2FlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank7DAO then

                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    else
                    end
                    
                    if player2PPSideBetWinDAO == false then

                        if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player2PerfectPairWinDAO()
                            SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank5DAO and cardRank5DAO == cardRank7DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "2" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "3" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "Ace" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "Ace" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "4" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "2" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "5" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "3" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "6" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "4" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "7" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "5" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "8" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "6" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "9" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "7" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "10" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "8" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "9" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Ace" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Ace" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank7DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank5DAO and cardRank5DAO == cardRank8DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "2" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "3" and cardRank8DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "Ace" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "Ace" and cardRank8DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "4" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "2" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "5" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "3" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "6" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "4" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "7" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "5" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "8" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "6" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "9" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "7" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "10" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "8" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "9" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Ace" and cardRank8DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Ace" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank8DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank5DAO and cardRank5DAO == cardRank8DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "2" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "3" and cardRank8DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "Ace" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "Ace" and cardRank8DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "4" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "2" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "5" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "3" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "6" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "4" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "7" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "5" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "8" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "6" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "9" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "7" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "10" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "8" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "9" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Ace" and cardRank8DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Ace" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank8DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank4DAO == cardRank5DAO and cardRank5DAO == cardRank9DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "2" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "3" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "Ace" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "Ace" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "4" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "2" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "5" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "3" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "6" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "4" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "7" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "5" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "8" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "6" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "9" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "7" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "10" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "8" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "9" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Ace" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Ace" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank4DAO == cardRank9DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank4DAO == cardRank5DAO and cardRank5DAO == cardRank9DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "2" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "3" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "Ace" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "Ace" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "4" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "2" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "5" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "3" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "6" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "4" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "7" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "5" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "8" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "6" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "9" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "7" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "10" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "8" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "9" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Ace" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Ace" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank4DAO == cardRank9DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets1234DAO()

    -- When it reaches Player 1: 3rd Card
    if turnDAO == 9 then

        -- Set all side bet text amounts to red initially
        player1213AmountTextDAO:SetTextColor(1, 0, 0)
        player1PPAmountTextDAO:SetTextColor(1, 0, 0)
        player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player2213AmountTextDAO:SetTextColor(1, 0, 0)
        player2PPAmountTextDAO:SetTextColor(1, 0, 0)
        player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 1: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 2: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 3: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Player 4: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 1: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 2: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank8DAO = string.match(dealtCardsDAO[8], "([%a%d]+)")
        cardSuit8DAO = string.match(dealtCardsDAO[8], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank9DAO = string.match(dealtCardsDAO[9], "([%a%d]+)")
        cardSuit9DAO = string.match(dealtCardsDAO[9], "of%s+(%a+)")

        -- Player 1
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank5DAO and cardRank5DAO == cardRank6DAO then

                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end

                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player1PPSideBetWinDAO == false then

                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "2" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "3" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "Ace" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "Ace" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank5DAO == "4" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "2" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank5DAO == "5" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "3" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank5DAO == "6" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "4" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank5DAO == "7" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "5" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank5DAO == "8" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "6" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank5DAO == "9" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "7" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank5DAO == "10" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "8" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "9" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank5DAO == "Ace" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Ace" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1FlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank6DAO then

                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    else
                    end
                    
                    if player1PPSideBetWinDAO == false then

                        if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player1PerfectPairWinDAO()
                            SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank5DAO and cardRank5DAO == cardRank6DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "2" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "3" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "Ace" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "Ace" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "3" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank5DAO == "4" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "2" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "2" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "4" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank5DAO == "5" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "3" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "3" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "5" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank5DAO == "6" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "4" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "4" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "6" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank5DAO == "7" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "5" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "5" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "7" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank5DAO == "8" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "6" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "6" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "8" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank5DAO == "9" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "7" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "7" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "9" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank5DAO == "10" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "8" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "8" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "9" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "9" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "10" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "10" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Jack" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Jack" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "King" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank5DAO == "Ace" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Ace" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank5DAO == "Queen" and cardRank6DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "Queen" and cardRank6DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank5DAO == "King" and cardRank6DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank6DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 2
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank5DAO and cardRank5DAO == cardRank7DAO then

                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end

                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player2PPSideBetWinDAO == false then

                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "2" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "3" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "Ace" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "Ace" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank5DAO == "4" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "2" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank5DAO == "5" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "3" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank5DAO == "6" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "4" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank5DAO == "7" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "5" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank5DAO == "8" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "6" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank5DAO == "9" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "7" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank5DAO == "10" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "8" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "9" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank5DAO == "Ace" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Ace" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2FlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank7DAO then

                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    else
                    end
                    
                    if player2PPSideBetWinDAO == false then

                        if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player2PerfectPairWinDAO()
                            SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank5DAO and cardRank5DAO == cardRank7DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "2" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "3" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "Ace" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "Ace" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "3" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank5DAO == "4" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "2" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "2" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "4" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank5DAO == "5" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "3" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "3" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "5" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank5DAO == "6" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "4" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "4" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "6" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank5DAO == "7" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "5" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "5" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "7" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank5DAO == "8" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "6" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "6" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "8" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank5DAO == "9" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "7" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "7" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "9" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank5DAO == "10" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "8" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "8" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "9" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "9" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "10" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "10" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Jack" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Jack" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "King" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank5DAO == "Ace" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Ace" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank5DAO == "Queen" and cardRank7DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "Queen" and cardRank7DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank5DAO == "King" and cardRank7DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank7DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank5DAO and cardRank5DAO == cardRank8DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "2" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "3" and cardRank8DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "Ace" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "Ace" and cardRank8DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank5DAO == "4" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "2" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank5DAO == "5" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "3" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank5DAO == "6" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "4" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank5DAO == "7" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "5" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank5DAO == "8" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "6" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank5DAO == "9" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "7" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank5DAO == "10" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "8" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "9" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank5DAO == "Ace" and cardRank8DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Ace" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank8DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank5DAO and cardRank5DAO == cardRank8DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "2" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "3" and cardRank8DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "Ace" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "Ace" and cardRank8DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "3" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank5DAO == "4" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "2" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "2" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "4" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank5DAO == "5" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "3" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "3" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "5" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank5DAO == "6" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "4" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "4" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "6" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank5DAO == "7" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "5" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "5" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "7" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank5DAO == "8" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "6" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "6" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "8" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank5DAO == "9" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "7" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "7" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "9" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank5DAO == "10" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "8" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "8" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "9" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "9" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "10" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "10" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Jack" and cardRank8DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Jack" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "King" and cardRank8DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank5DAO == "Ace" and cardRank8DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Ace" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank5DAO == "Queen" and cardRank8DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "Queen" and cardRank8DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank5DAO == "King" and cardRank8DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank8DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit8DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit8DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit8DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit8DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank4DAO == cardRank5DAO and cardRank5DAO == cardRank9DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "2" and cardRank9DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "3" and cardRank9DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "Ace" and cardRank9DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "Ace" and cardRank9DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "2" and cardRank5DAO == "4" and cardRank9DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "2" and cardRank9DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "3" and cardRank5DAO == "5" and cardRank9DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "3" and cardRank9DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "4" and cardRank5DAO == "6" and cardRank9DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "4" and cardRank9DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "5" and cardRank5DAO == "7" and cardRank9DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "5" and cardRank9DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "6" and cardRank5DAO == "8" and cardRank9DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "6" and cardRank9DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "7" and cardRank5DAO == "9" and cardRank9DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "7" and cardRank9DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "8" and cardRank5DAO == "10" and cardRank9DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "8" and cardRank9DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "9" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "9" and cardRank9DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "10" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Jack" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Queen" and cardRank5DAO == "Ace" and cardRank9DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Ace" and cardRank9DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank4DAO == "Ace" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank4DAO == cardRank9DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank4DAO == cardRank5DAO and cardRank5DAO == cardRank9DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "2" and cardRank9DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "3" and cardRank9DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "Ace" and cardRank9DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "Ace" and cardRank9DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "3" and cardRank9DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "2" and cardRank5DAO == "4" and cardRank9DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "2" and cardRank9DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "2" and cardRank9DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "4" and cardRank9DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "3" and cardRank5DAO == "5" and cardRank9DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "3" and cardRank9DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "3" and cardRank9DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "5" and cardRank9DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "4" and cardRank5DAO == "6" and cardRank9DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "4" and cardRank9DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "4" and cardRank9DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "6" and cardRank9DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "5" and cardRank5DAO == "7" and cardRank9DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "5" and cardRank9DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "5" and cardRank9DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "7" and cardRank9DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "6" and cardRank5DAO == "8" and cardRank9DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "6" and cardRank9DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "6" and cardRank9DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "8" and cardRank9DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "7" and cardRank5DAO == "9" and cardRank9DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "7" and cardRank9DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "7" and cardRank9DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "9" and cardRank9DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "8" and cardRank5DAO == "10" and cardRank9DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "8" and cardRank9DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "8" and cardRank9DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "9" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "9" and cardRank9DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "9" and cardRank9DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "10" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "10" and cardRank9DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "10" and cardRank9DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Jack" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Jack" and cardRank9DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Jack" and cardRank9DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "King" and cardRank9DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Queen" and cardRank5DAO == "Ace" and cardRank9DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Ace" and cardRank9DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "King" and cardRank5DAO == "Queen" and cardRank9DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "Queen" and cardRank9DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank4DAO == "Ace" and cardRank5DAO == "King" and cardRank9DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank4DAO == cardRank9DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit4DAO == "Spades" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Hearts" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit4DAO == "Spades" and cardSuit9DAO == "Clubs" or cardSuit4DAO == "Clubs" and cardSuit9DAO == "Spades" or cardSuit4DAO == "Hearts" and cardSuit9DAO == "Diamonds" or cardSuit4DAO == "Diamonds" and cardSuit9DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets345DAO()

    -- When it reaches Player 3: 3rd Card
    if turnDAO == 7 then

        -- Set all side bet text amounts to red initially
        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 3: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 4: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")

        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank5DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank5DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank6DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank6DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank7DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets245DAO()

    -- When it reaches Player 2: 3rd Card
    if turnDAO == 7 then

        -- Set all side bet text amounts to red initially
        player2213AmountTextDAO:SetTextColor(1, 0, 0)
        player2PPAmountTextDAO:SetTextColor(1, 0, 0)
        player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 2: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 4: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 2: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")

        -- Player 2
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end

                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player2PPSideBetWinDAO == false then

                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2FlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank5DAO then

                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    else
                    end
                    
                    if player2PPSideBetWinDAO == false then

                        if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player2PerfectPairWinDAO()
                            SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank5DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank6DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank6DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank7DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets235DAO()

    -- When it reaches Player 2: 3rd Card
    if turnDAO == 7 then

        -- Set all side bet text amounts to red initially
        player2213AmountTextDAO:SetTextColor(1, 0, 0)
        player2PPAmountTextDAO:SetTextColor(1, 0, 0)
        player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 2: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 3: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 2: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")

        -- Player 2
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end

                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player2PPSideBetWinDAO == false then

                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2FlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank5DAO then

                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    else
                    end
                    
                    if player2PPSideBetWinDAO == false then

                        if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player2PerfectPairWinDAO()
                            SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank5DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank6DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank6DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank7DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets234DAO()

    -- When it reaches Player 2: 3rd Card
    if turnDAO == 7 then

        -- Set all side bet text amounts to red initially
        player2213AmountTextDAO:SetTextColor(1, 0, 0)
        player2PPAmountTextDAO:SetTextColor(1, 0, 0)
        player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 2: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 3: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 4: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 2: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")

        -- Player 2
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end

                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player2PPSideBetWinDAO == false then

                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2FlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank5DAO then

                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    else
                    end
                    
                    if player2PPSideBetWinDAO == false then

                        if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player2PerfectPairWinDAO()
                            SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank5DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank6DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank6DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank7DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank7DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets145DAO()

    -- When it reaches Player 1: 3rd Card
    if turnDAO == 7 then

        -- Set all side bet text amounts to red initially
        player1213AmountTextDAO:SetTextColor(1, 0, 0)
        player1PPAmountTextDAO:SetTextColor(1, 0, 0)
        player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 1: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 4: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 1: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")

        -- Player 1
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end

                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player1PPSideBetWinDAO == false then

                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1FlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank5DAO then

                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    else
                    end
                    
                    if player1PPSideBetWinDAO == false then

                        if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player1PerfectPairWinDAO()
                            SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank6DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank6DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank7DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets135DAO()

    -- When it reaches Player 1: 3rd Card
    if turnDAO == 7 then

        -- Set all side bet text amounts to red initially
        player1213AmountTextDAO:SetTextColor(1, 0, 0)
        player1PPAmountTextDAO:SetTextColor(1, 0, 0)
        player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 1: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 3: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 1: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")

        -- Player 1
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end

                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player1PPSideBetWinDAO == false then

                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1FlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank5DAO then

                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    else
                    end
                    
                    if player1PPSideBetWinDAO == false then

                        if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player1PerfectPairWinDAO()
                            SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank6DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank6DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank7DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets134DAO()

    -- When it reaches Player 1: 3rd Card
    if turnDAO == 7 then

        -- Set all side bet text amounts to red initially
        player1213AmountTextDAO:SetTextColor(1, 0, 0)
        player1PPAmountTextDAO:SetTextColor(1, 0, 0)
        player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 1: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 3: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 4: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 1: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")

        -- Player 1
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end

                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player1PPSideBetWinDAO == false then

                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1FlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank5DAO then

                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    else
                    end
                    
                    if player1PPSideBetWinDAO == false then

                        if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player1PerfectPairWinDAO()
                            SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank6DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank6DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank7DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank7DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets125DAO()

    -- When it reaches Player 1: 3rd Card
    if turnDAO == 7 then

        -- Set all side bet text amounts to red initially
        player1213AmountTextDAO:SetTextColor(1, 0, 0)
        player1PPAmountTextDAO:SetTextColor(1, 0, 0)
        player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player2213AmountTextDAO:SetTextColor(1, 0, 0)
        player2PPAmountTextDAO:SetTextColor(1, 0, 0)
        player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 1: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 2: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 1: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 2: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")

        -- Player 1
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end

                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player1PPSideBetWinDAO == false then

                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1FlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank5DAO then

                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    else
                    end
                    
                    if player1PPSideBetWinDAO == false then

                        if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player1PerfectPairWinDAO()
                            SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 2
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end

                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player2PPSideBetWinDAO == false then

                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2FlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank6DAO then

                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    else
                    end
                    
                    if player2PPSideBetWinDAO == false then

                        if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player2PerfectPairWinDAO()
                            SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank6DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank7DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank7DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets124DAO()

    -- When it reaches Player 1: 3rd Card
    if turnDAO == 7 then

        -- Set all side bet text amounts to red initially
        player1213AmountTextDAO:SetTextColor(1, 0, 0)
        player1PPAmountTextDAO:SetTextColor(1, 0, 0)
        player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player2213AmountTextDAO:SetTextColor(1, 0, 0)
        player2PPAmountTextDAO:SetTextColor(1, 0, 0)
        player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 1: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 2: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 4: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 1: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 2: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")

        -- Player 1
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end

                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player1PPSideBetWinDAO == false then

                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1FlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank5DAO then

                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    else
                    end
                    
                    if player1PPSideBetWinDAO == false then

                        if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player1PerfectPairWinDAO()
                            SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 2
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end

                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player2PPSideBetWinDAO == false then

                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2FlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank6DAO then

                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    else
                    end
                    
                    if player2PPSideBetWinDAO == false then

                        if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player2PerfectPairWinDAO()
                            SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank6DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank7DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank7DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets123DAO()

    -- When it reaches Player 1: 3rd Card
    if turnDAO == 7 then

        -- Set all side bet text amounts to red initially
        player1213AmountTextDAO:SetTextColor(1, 0, 0)
        player1PPAmountTextDAO:SetTextColor(1, 0, 0)
        player1InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player2213AmountTextDAO:SetTextColor(1, 0, 0)
        player2PPAmountTextDAO:SetTextColor(1, 0, 0)
        player2InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 1: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 2: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Player 3: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 1: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")
        -- Player 2: 2nd Card
        cardRank6DAO = string.match(dealtCardsDAO[6], "([%a%d]+)")
        cardSuit6DAO = string.match(dealtCardsDAO[6], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank7DAO = string.match(dealtCardsDAO[7], "([%a%d]+)")
        cardSuit7DAO = string.match(dealtCardsDAO[7], "of%s+(%a+)")

        -- Player 1
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

                if player1SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                    player1SplitOfferedDAO = true
                else
                end

                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 1 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player1PPSideBetWinDAO == false then

                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1StraightFlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player1FlushWinDAO()
                    SendChatMessage("{star} Player 1 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank5DAO then

                    if player1SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                        player1SplitOfferedDAO = true
                    else
                    end
                    
                    if player1PPSideBetWinDAO == false then

                        if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player1PerfectPairWinDAO()
                            SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank4DAO and cardRank4DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 1 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "Ace" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "Ace" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "2" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "2" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "2" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "3" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "3" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "3" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "4" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "4" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "4" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "5" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "5" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "5" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "6" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "6" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "6" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "7" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "7" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "7" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "8" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "8" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "8" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "9" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "9" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "9" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "10" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "10" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "10" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Jack" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Jack" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Jack" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "King" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank4DAO == "Ace" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Ace" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank4DAO == "Queen" and cardRank5DAO == "Ace" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "Queen" and cardRank5DAO == "King" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank4DAO == "King" and cardRank5DAO == "Queen" then
            if player1213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player1StraightWinDAO()
                SendChatMessage("{star} Player 1 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank5DAO then

            if player1SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName1DAO .. ".", "RAID")
                player1SplitOfferedDAO = true
            else
            end

            if player1PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1PerfectPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1ColouredPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player1PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player1MixedPairWinDAO()
                        SendChatMessage("{star} Player 1 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 2
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

                if player2SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                    player2SplitOfferedDAO = true
                else
                end

                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 2 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player2PPSideBetWinDAO == false then

                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2StraightFlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player2FlushWinDAO()
                    SendChatMessage("{star} Player 2 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank6DAO then

                    if player2SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                        player2SplitOfferedDAO = true
                    else
                    end
                    
                    if player2PPSideBetWinDAO == false then

                        if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player2PerfectPairWinDAO()
                            SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank4DAO and cardRank4DAO == cardRank6DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 2 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "Ace" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "Ace" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "2" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "2" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "2" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "3" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "3" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "3" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "4" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "4" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "4" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "5" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "5" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "5" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "6" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "6" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "6" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "7" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "7" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "7" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "8" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "8" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "8" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "9" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "9" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "9" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "10" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "10" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "10" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Jack" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Jack" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Jack" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "King" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank4DAO == "Ace" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Ace" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank4DAO == "Queen" and cardRank6DAO == "Ace" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "Queen" and cardRank6DAO == "King" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank4DAO == "King" and cardRank6DAO == "Queen" then
            if player2213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player2StraightWinDAO()
                SendChatMessage("{star} Player 2 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank6DAO then

            if player2SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName2DAO .. ".", "RAID")
                player2SplitOfferedDAO = true
            else
            end

            if player2PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2PerfectPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit6DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit6DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit6DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit6DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2ColouredPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player2PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player2MixedPairWinDAO()
                        SendChatMessage("{star} Player 2 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank3DAO == cardRank7DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank3DAO == cardRank4DAO and cardRank4DAO == cardRank7DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "Ace" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "Ace" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "2" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "2" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "2" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "3" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "3" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "3" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "4" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "4" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "4" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "5" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "5" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "5" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "6" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "6" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "6" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "7" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "7" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "7" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "8" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "8" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "8" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "9" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "9" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "9" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "10" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "10" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "10" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Jack" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Jack" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Jack" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "King" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Queen" and cardRank4DAO == "Ace" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Ace" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "King" and cardRank4DAO == "Queen" and cardRank7DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "Queen" and cardRank7DAO == "King" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank3DAO == "Ace" and cardRank4DAO == "King" and cardRank7DAO == "Queen" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank3DAO == cardRank7DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit3DAO == "Spades" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Hearts" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit3DAO == "Spades" and cardSuit7DAO == "Clubs" or cardSuit3DAO == "Clubs" and cardSuit7DAO == "Spades" or cardSuit3DAO == "Hearts" and cardSuit7DAO == "Diamonds" or cardSuit3DAO == "Diamonds" and cardSuit7DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end
    end
end
function SideBets45DAO()

    -- When it reaches Player 4: 3rd Card
    if turnDAO == 5 then

        -- Set all side bet text amounts to red initially
        player4213AmountTextDAO:SetTextColor(1, 0, 0)
        player4PPAmountTextDAO:SetTextColor(1, 0, 0)
        player4InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 4: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Player 4: 2nd Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")

        -- Player 4
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank3DAO and cardRank3DAO == cardRank4DAO then

                if player4SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                    player4SplitOfferedDAO = true
                else
                end

                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 4 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player4PPSideBetWinDAO == false then

                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank3DAO == "2" and cardRank4DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank3DAO == "3" and cardRank4DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank3DAO == "Ace" and cardRank4DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank3DAO == "3" and cardRank4DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "Ace" and cardRank4DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "2" and cardRank4DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank3DAO == "3" and cardRank4DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank3DAO == "4" and cardRank4DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "4" and cardRank4DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "2" and cardRank4DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "2" and cardRank4DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "3" and cardRank4DAO == "2" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "4" and cardRank4DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "5" and cardRank4DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "5" and cardRank4DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "3" and cardRank4DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "3" and cardRank4DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "4" and cardRank4DAO == "3" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "5" and cardRank4DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "6" and cardRank4DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "6" and cardRank4DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "4" and cardRank4DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "4" and cardRank4DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "5" and cardRank4DAO == "4" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "6" and cardRank4DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "7" and cardRank4DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "7" and cardRank4DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "5" and cardRank4DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "5" and cardRank4DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "6" and cardRank4DAO == "5" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "7" and cardRank4DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "8" and cardRank4DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "8" and cardRank4DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "6" and cardRank4DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "6" and cardRank4DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "7" and cardRank4DAO == "6" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "8" and cardRank4DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "9" and cardRank4DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "9" and cardRank4DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "7" and cardRank4DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "7" and cardRank4DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "8" and cardRank4DAO == "7" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "9" and cardRank4DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "10" and cardRank4DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "10" and cardRank4DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "8" and cardRank4DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "8" and cardRank4DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "9" and cardRank4DAO == "8" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "10" and cardRank4DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "Jack" and cardRank4DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "Jack" and cardRank4DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "9" and cardRank4DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "9" and cardRank4DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "10" and cardRank4DAO == "9" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "Jack" and cardRank4DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "Queen" and cardRank4DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "Queen" and cardRank4DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "10" and cardRank4DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "10" and cardRank4DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "Jack" and cardRank4DAO == "10" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "Queen" and cardRank4DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "King" and cardRank4DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "King" and cardRank4DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "Jack" and cardRank4DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank3DAO == "Jack" and cardRank4DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank3DAO == "Queen" and cardRank4DAO == "Jack" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "King" and cardRank4DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "Ace" and cardRank4DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank3DAO == "Ace" and cardRank4DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank3DAO == "Queen" and cardRank4DAO == "Ace" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank3DAO == "Queen" and cardRank4DAO == "King" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank3DAO == "King" and cardRank4DAO == "Queen" then
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4StraightFlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player4FlushWinDAO()
                    SendChatMessage("{star} Player 4 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank4DAO then

                    if player4SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                        player4SplitOfferedDAO = true
                    else
                    end
                    
                    if player4PPSideBetWinDAO == false then

                        if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player4PerfectPairWinDAO()
                            SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank3DAO and cardRank3DAO == cardRank4DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 4 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit4DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank3DAO == "2" and cardRank4DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank3DAO == "3" and cardRank4DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank3DAO == "Ace" and cardRank4DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank3DAO == "3" and cardRank4DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "Ace" and cardRank4DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "2" and cardRank4DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank3DAO == "3" and cardRank4DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank3DAO == "4" and cardRank4DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "4" and cardRank4DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "2" and cardRank4DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "2" and cardRank4DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "3" and cardRank4DAO == "2" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "4" and cardRank4DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "5" and cardRank4DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "5" and cardRank4DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "3" and cardRank4DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "3" and cardRank4DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "4" and cardRank4DAO == "3" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "5" and cardRank4DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "6" and cardRank4DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "6" and cardRank4DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "4" and cardRank4DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "4" and cardRank4DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "5" and cardRank4DAO == "4" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "6" and cardRank4DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "7" and cardRank4DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "7" and cardRank4DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "5" and cardRank4DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "5" and cardRank4DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "6" and cardRank4DAO == "5" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "7" and cardRank4DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "8" and cardRank4DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "8" and cardRank4DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "6" and cardRank4DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "6" and cardRank4DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "7" and cardRank4DAO == "6" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "8" and cardRank4DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "9" and cardRank4DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "9" and cardRank4DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "7" and cardRank4DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "7" and cardRank4DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "8" and cardRank4DAO == "7" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "9" and cardRank4DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "10" and cardRank4DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "10" and cardRank4DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "8" and cardRank4DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank3DAO == "8" and cardRank4DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank3DAO == "9" and cardRank4DAO == "8" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "10" and cardRank4DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "Jack" and cardRank4DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank3DAO == "Jack" and cardRank4DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank3DAO == "9" and cardRank4DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank3DAO == "9" and cardRank4DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank3DAO == "10" and cardRank4DAO == "9" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank3DAO == "Jack" and cardRank4DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank3DAO == "Queen" and cardRank4DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank3DAO == "Queen" and cardRank4DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank3DAO == "10" and cardRank4DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank3DAO == "10" and cardRank4DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank3DAO == "Jack" and cardRank4DAO == "10" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank3DAO == "Queen" and cardRank4DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank3DAO == "King" and cardRank4DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank3DAO == "King" and cardRank4DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank3DAO == "Jack" and cardRank4DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank3DAO == "Jack" and cardRank4DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank3DAO == "Queen" and cardRank4DAO == "Jack" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank3DAO == "King" and cardRank4DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Queen" and cardRank3DAO == "Ace" and cardRank4DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank3DAO == "Ace" and cardRank4DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "King" and cardRank3DAO == "Queen" and cardRank4DAO == "Ace" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank3DAO == "Queen" and cardRank4DAO == "King" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank3DAO == "King" and cardRank4DAO == "Queen" then
            if player4213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player4StraightWinDAO()
                SendChatMessage("{star} Player 4 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank1DAO == cardRank4DAO then

            if player4SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName4DAO .. ".", "RAID")
                player4SplitOfferedDAO = true
            else
            end

            if player4PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4PerfectPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit4DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4ColouredPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player4PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player4MixedPairWinDAO()
                        SendChatMessage("{star} Player 4 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end





        -- Player 5
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit2DAO == "Spades" and cardSuit3DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit3DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit3DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit3DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank2DAO == cardRank3DAO and cardRank3DAO == cardRank5DAO then

                if player5SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                    player5SplitOfferedDAO = true
                else
                end

                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 5 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player5PPSideBetWinDAO == false then

                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank2DAO == "Ace" and cardRank3DAO == "2" and cardRank5DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank3DAO == "3" and cardRank5DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank3DAO == "Ace" and cardRank5DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank3DAO == "3" and cardRank5DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank3DAO == "Ace" and cardRank5DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank3DAO == "2" and cardRank5DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank3DAO == "3" and cardRank5DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "2" and cardRank3DAO == "4" and cardRank5DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank3DAO == "4" and cardRank5DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank3DAO == "2" and cardRank5DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank3DAO == "2" and cardRank5DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank3DAO == "3" and cardRank5DAO == "2" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank3DAO == "4" and cardRank5DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "3" and cardRank3DAO == "5" and cardRank5DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank3DAO == "5" and cardRank5DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank3DAO == "3" and cardRank5DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank3DAO == "3" and cardRank5DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank3DAO == "4" and cardRank5DAO == "3" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank3DAO == "5" and cardRank5DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "4" and cardRank3DAO == "6" and cardRank5DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank3DAO == "6" and cardRank5DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank3DAO == "4" and cardRank5DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank3DAO == "4" and cardRank5DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank3DAO == "5" and cardRank5DAO == "4" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank3DAO == "6" and cardRank5DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "5" and cardRank3DAO == "7" and cardRank5DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank3DAO == "7" and cardRank5DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank3DAO == "5" and cardRank5DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank3DAO == "5" and cardRank5DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank3DAO == "6" and cardRank5DAO == "5" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank3DAO == "7" and cardRank5DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "6" and cardRank3DAO == "8" and cardRank5DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank3DAO == "8" and cardRank5DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank3DAO == "6" and cardRank5DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank3DAO == "6" and cardRank5DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank3DAO == "7" and cardRank5DAO == "6" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank3DAO == "8" and cardRank5DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "7" and cardRank3DAO == "9" and cardRank5DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank3DAO == "9" and cardRank5DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank3DAO == "7" and cardRank5DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank3DAO == "7" and cardRank5DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank3DAO == "8" and cardRank5DAO == "7" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank3DAO == "9" and cardRank5DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "8" and cardRank3DAO == "10" and cardRank5DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank3DAO == "10" and cardRank5DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank3DAO == "8" and cardRank5DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank3DAO == "8" and cardRank5DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank3DAO == "9" and cardRank5DAO == "8" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank3DAO == "10" and cardRank5DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "9" and cardRank3DAO == "Jack" and cardRank5DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank3DAO == "Jack" and cardRank5DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank3DAO == "9" and cardRank5DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank3DAO == "9" and cardRank5DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank3DAO == "10" and cardRank5DAO == "9" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank3DAO == "Jack" and cardRank5DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "10" and cardRank3DAO == "Queen" and cardRank5DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank3DAO == "Queen" and cardRank5DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank3DAO == "10" and cardRank5DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank3DAO == "10" and cardRank5DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank3DAO == "Jack" and cardRank5DAO == "10" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank3DAO == "Queen" and cardRank5DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Jack" and cardRank3DAO == "King" and cardRank5DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank3DAO == "King" and cardRank5DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank3DAO == "Jack" and cardRank5DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank3DAO == "Jack" and cardRank5DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank3DAO == "Queen" and cardRank5DAO == "Jack" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank3DAO == "King" and cardRank5DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Queen" and cardRank3DAO == "Ace" and cardRank5DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank3DAO == "Ace" and cardRank5DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "King" and cardRank3DAO == "Queen" and cardRank5DAO == "Ace" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank3DAO == "Queen" and cardRank5DAO == "King" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank2DAO == "Ace" and cardRank3DAO == "King" and cardRank5DAO == "Queen" then
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5StraightFlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player5FlushWinDAO()
                    SendChatMessage("{star} Player 5 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank2DAO == cardRank5DAO then

                    if player5SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                        player5SplitOfferedDAO = true
                    else
                    end
                    
                    if player5PPSideBetWinDAO == false then

                        if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player5PerfectPairWinDAO()
                            SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank2DAO == cardRank3DAO and cardRank3DAO == cardRank5DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 5 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank2DAO == "Ace" and cardRank3DAO == "2" and cardRank5DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank3DAO == "3" and cardRank5DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank3DAO == "Ace" and cardRank5DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank3DAO == "3" and cardRank5DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank3DAO == "Ace" and cardRank5DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank3DAO == "2" and cardRank5DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank3DAO == "3" and cardRank5DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "2" and cardRank3DAO == "4" and cardRank5DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank3DAO == "4" and cardRank5DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank3DAO == "2" and cardRank5DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank3DAO == "2" and cardRank5DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank3DAO == "3" and cardRank5DAO == "2" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank3DAO == "4" and cardRank5DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "3" and cardRank3DAO == "5" and cardRank5DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank3DAO == "5" and cardRank5DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank3DAO == "3" and cardRank5DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank3DAO == "3" and cardRank5DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank3DAO == "4" and cardRank5DAO == "3" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank3DAO == "5" and cardRank5DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "4" and cardRank3DAO == "6" and cardRank5DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank3DAO == "6" and cardRank5DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank3DAO == "4" and cardRank5DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank3DAO == "4" and cardRank5DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank3DAO == "5" and cardRank5DAO == "4" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank3DAO == "6" and cardRank5DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "5" and cardRank3DAO == "7" and cardRank5DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank3DAO == "7" and cardRank5DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank3DAO == "5" and cardRank5DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank3DAO == "5" and cardRank5DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank3DAO == "6" and cardRank5DAO == "5" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank3DAO == "7" and cardRank5DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "6" and cardRank3DAO == "8" and cardRank5DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank3DAO == "8" and cardRank5DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank3DAO == "6" and cardRank5DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank3DAO == "6" and cardRank5DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank3DAO == "7" and cardRank5DAO == "6" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank3DAO == "8" and cardRank5DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "7" and cardRank3DAO == "9" and cardRank5DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank3DAO == "9" and cardRank5DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank3DAO == "7" and cardRank5DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank3DAO == "7" and cardRank5DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank3DAO == "8" and cardRank5DAO == "7" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank3DAO == "9" and cardRank5DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "8" and cardRank3DAO == "10" and cardRank5DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank3DAO == "10" and cardRank5DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank3DAO == "8" and cardRank5DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank3DAO == "8" and cardRank5DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank3DAO == "9" and cardRank5DAO == "8" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank3DAO == "10" and cardRank5DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "9" and cardRank3DAO == "Jack" and cardRank5DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank3DAO == "Jack" and cardRank5DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank3DAO == "9" and cardRank5DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank3DAO == "9" and cardRank5DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank3DAO == "10" and cardRank5DAO == "9" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank3DAO == "Jack" and cardRank5DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "10" and cardRank3DAO == "Queen" and cardRank5DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank3DAO == "Queen" and cardRank5DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank3DAO == "10" and cardRank5DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank3DAO == "10" and cardRank5DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank3DAO == "Jack" and cardRank5DAO == "10" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank3DAO == "Queen" and cardRank5DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Jack" and cardRank3DAO == "King" and cardRank5DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank3DAO == "King" and cardRank5DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank3DAO == "Jack" and cardRank5DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank3DAO == "Jack" and cardRank5DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank3DAO == "Queen" and cardRank5DAO == "Jack" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank3DAO == "King" and cardRank5DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Queen" and cardRank3DAO == "Ace" and cardRank5DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank3DAO == "Ace" and cardRank5DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "King" and cardRank3DAO == "Queen" and cardRank5DAO == "Ace" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank3DAO == "Queen" and cardRank5DAO == "King" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank2DAO == "Ace" and cardRank3DAO == "King" and cardRank5DAO == "Queen" then
            if player5213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player5StraightWinDAO()
                SendChatMessage("{star} Player 5 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end                   



        -- Perfect Pair Check
        elseif cardRank2DAO == cardRank5DAO then

            if player5SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName5DAO .. ".", "RAID")
                player5SplitOfferedDAO = true
            else
            end

            if player5PPSideBetWinDAO == false then

                if cardSuit2DAO == "Spades" and cardSuit5DAO == "Spades" or cardSuit2DAO == "Clubs" and cardSuit5DAO == "Clubs" or cardSuit2DAO == "Hearts" and cardSuit5DAO == "Hearts" or cardSuit2DAO == "Diamonds" and cardSuit5DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5PerfectPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit2DAO == "Spades" and cardSuit5DAO == "Clubs" or cardSuit2DAO == "Clubs" and cardSuit5DAO == "Spades" or cardSuit2DAO == "Hearts" and cardSuit5DAO == "Diamonds" or cardSuit2DAO == "Diamonds" and cardSuit5DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5ColouredPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player5PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player5MixedPairWinDAO()
                        SendChatMessage("{star} Player 5 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end
        end

    end
end
function SideBets35DAO()

    -- When it reaches Player 3: 3rd Card
    if turnDAO == 5 then

        -- Set all side bet text amounts to red initially
        player3213AmountTextDAO:SetTextColor(1, 0, 0)
        player3PPAmountTextDAO:SetTextColor(1, 0, 0)
        player3InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        player5213AmountTextDAO:SetTextColor(1, 0, 0)
        player5PPAmountTextDAO:SetTextColor(1, 0, 0)
        player5InsuranceAmountTextDAO:SetTextColor(1, 0, 0)

        -- Allocates card ranksDAO and suitsDAO for each card dealt
        -- Player 3: 1st Card
        cardRank1DAO = string.match(dealtCardsDAO[1], "([%a%d]+)")
        cardSuit1DAO = string.match(dealtCardsDAO[1], "of%s+(%a+)")
        -- Player 5: 1st Card
        cardRank2DAO = string.match(dealtCardsDAO[2], "([%a%d]+)")
        cardSuit2DAO = string.match(dealtCardsDAO[2], "of%s+(%a+)")
        -- Dealer: 1st Card
        cardRank3DAO = string.match(dealtCardsDAO[3], "([%a%d]+)")
        cardSuit3DAO = string.match(dealtCardsDAO[3], "of%s+(%a+)")
        -- Player 3: 2nd Card
        cardRank4DAO = string.match(dealtCardsDAO[4], "([%a%d]+)")
        cardSuit4DAO = string.match(dealtCardsDAO[4], "of%s+(%a+)")
        -- Player 5: 2nd Card
        cardRank5DAO = string.match(dealtCardsDAO[5], "([%a%d]+)")
        cardSuit5DAO = string.match(dealtCardsDAO[5], "of%s+(%a+)")

        -- Player 3
        -- 21+3 Check (Flush / Straight Flush / Suited Three of a Kind)
        if cardSuit1DAO == "Spades" and cardSuit3DAO == "Spades" and cardSuit4DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit3DAO == "Clubs" and cardSuit4DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit3DAO == "Hearts" and cardSuit4DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit3DAO == "Diamonds" and cardSuit4DAO == "Diamonds" then

            -- Suited Three of a Kind (100:1)
            if cardRank1DAO == cardRank3DAO and cardRank3DAO == cardRank4DAO then

                if player3SplitOfferedDAO == false then
                    SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                    player3SplitOfferedDAO = true
                else
                end

                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3SuitedThreeOfAKindWinDAO()
                    SendChatMessage("{star} Player 3 hit a Suited Three of a Kind (Payout is " .. suitedThreeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if player3PPSideBetWinDAO == false then

                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end

            -- Straight Flush (40:1)
            elseif cardRank1DAO == "Ace" and cardRank3DAO == "2" and cardRank4DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank3DAO == "3" and cardRank4DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank3DAO == "Ace" and cardRank4DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank3DAO == "3" and cardRank4DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "Ace" and cardRank4DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "2" and cardRank4DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank3DAO == "3" and cardRank4DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "2" and cardRank3DAO == "4" and cardRank4DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "4" and cardRank4DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "2" and cardRank4DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "2" and cardRank4DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "3" and cardRank4DAO == "2" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "4" and cardRank4DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "3" and cardRank3DAO == "5" and cardRank4DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "5" and cardRank4DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "3" and cardRank4DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "3" and cardRank4DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "4" and cardRank4DAO == "3" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "5" and cardRank4DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "4" and cardRank3DAO == "6" and cardRank4DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "6" and cardRank4DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "4" and cardRank4DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "4" and cardRank4DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "5" and cardRank4DAO == "4" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "6" and cardRank4DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "5" and cardRank3DAO == "7" and cardRank4DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "7" and cardRank4DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "5" and cardRank4DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "5" and cardRank4DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "6" and cardRank4DAO == "5" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "7" and cardRank4DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "6" and cardRank3DAO == "8" and cardRank4DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "8" and cardRank4DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "6" and cardRank4DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "6" and cardRank4DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "7" and cardRank4DAO == "6" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "8" and cardRank4DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "7" and cardRank3DAO == "9" and cardRank4DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "9" and cardRank4DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "7" and cardRank4DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "7" and cardRank4DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "8" and cardRank4DAO == "7" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "9" and cardRank4DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "8" and cardRank3DAO == "10" and cardRank4DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "10" and cardRank4DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "8" and cardRank4DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "8" and cardRank4DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "9" and cardRank4DAO == "8" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "10" and cardRank4DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "9" and cardRank3DAO == "Jack" and cardRank4DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "Jack" and cardRank4DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "9" and cardRank4DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "9" and cardRank4DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "10" and cardRank4DAO == "9" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "Jack" and cardRank4DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "10" and cardRank3DAO == "Queen" and cardRank4DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "Queen" and cardRank4DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "10" and cardRank4DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "10" and cardRank4DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "Jack" and cardRank4DAO == "10" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "Queen" and cardRank4DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Jack" and cardRank3DAO == "King" and cardRank4DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "King" and cardRank4DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "Jack" and cardRank4DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank3DAO == "Jack" and cardRank4DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank3DAO == "Queen" and cardRank4DAO == "Jack" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "King" and cardRank4DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Queen" and cardRank3DAO == "Ace" and cardRank4DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank3DAO == "Ace" and cardRank4DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "King" and cardRank3DAO == "Queen" and cardRank4DAO == "Ace" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank3DAO == "Queen" and cardRank4DAO == "King" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end
            elseif cardRank1DAO == "Ace" and cardRank3DAO == "King" and cardRank4DAO == "Queen" then
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3StraightFlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Straight Flush (Payout is " .. straightFlushPayoutDAO .. ":1) - congratulations!", "RAID")
                end


            -- Flush (5:1)
            else
                if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                    SendChatMessage("{skull} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                else
                    player3FlushWinDAO()
                    SendChatMessage("{star} Player 3 hit a Flush (Payout is " .. flushPayoutDAO .. ":1) - congratulations!", "RAID")
                end

                if cardRank1DAO == cardRank4DAO then

                    if player3SplitOfferedDAO == false then
                        SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                        player3SplitOfferedDAO = true
                    else
                    end
                    
                    if player3PPSideBetWinDAO == false then

                        if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                            SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                        else
                            player3PerfectPairWinDAO()
                            SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                        end
                    end
                end
            end

        -- Three of a Kind (30:1)
        elseif cardRank1DAO == cardRank3DAO and cardRank3DAO == cardRank4DAO then

            if player3SplitOfferedDAO == false then
                SendChatMessage("{triangle} Split is available, " .. unitName3DAO .. ".", "RAID")
                player3SplitOfferedDAO = true
            else
            end

            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3ThreeOfAKindWinDAO()
                SendChatMessage("{star} Player 3 hit a Three of a Kind (Payout is " .. threeOfAKindPayoutDAO .. ":1) - congratulations!", "RAID")
            end

            if player3PPSideBetWinDAO == false then

                if cardSuit1DAO == "Spades" and cardSuit4DAO == "Spades" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Clubs" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Hearts" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Diamonds" then
                    -- Perfect Pair (30:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3PerfectPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Perfect Pair (Payout is " .. perfectPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                elseif cardSuit1DAO == "Spades" and cardSuit4DAO == "Clubs" or cardSuit1DAO == "Clubs" and cardSuit4DAO == "Spades" or cardSuit1DAO == "Hearts" and cardSuit4DAO == "Diamonds" or cardSuit1DAO == "Diamonds" and cardSuit4DAO == "Hearts" then
                    -- Coloured Pair (10:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3ColouredPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Coloured Pair (Payout is " .. colouredPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                else
                    -- Mixed Pair (5:1)
                    if player3PPAmountTextDAO:GetText() == "PP Side Bet: N/A" then
                        SendChatMessage("{skull} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
                    else
                        player3MixedPairWinDAO()
                        SendChatMessage("{star} Player 3 hit a Mixed Pair (Payout is " .. mixedPairPayoutDAO .. ":1) - congratulations!", "RAID")
                    end
                end
            end

        -- Straight (10:1)
        elseif cardRank1DAO == "Ace" and cardRank3DAO == "2" and cardRank4DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Ace" and cardRank3DAO == "3" and cardRank4DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank3DAO == "Ace" and cardRank4DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank3DAO == "3" and cardRank4DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "Ace" and cardRank4DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "2" and cardRank4DAO == "Ace" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank3DAO == "3" and cardRank4DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "2" and cardRank3DAO == "4" and cardRank4DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "4" and cardRank4DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "2" and cardRank4DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "2" and cardRank4DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "3" and cardRank4DAO == "2" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "4" and cardRank4DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "3" and cardRank3DAO == "5" and cardRank4DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "5" and cardRank4DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "3" and cardRank4DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "3" and cardRank4DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "4" and cardRank4DAO == "3" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "5" and cardRank4DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "4" and cardRank3DAO == "6" and cardRank4DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "6" and cardRank4DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "4" and cardRank4DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "4" and cardRank4DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "5" and cardRank4DAO == "4" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "6" and cardRank4DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "5" and cardRank3DAO == "7" and cardRank4DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "7" and cardRank4DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "5" and cardRank4DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "5" and cardRank4DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "6" and cardRank4DAO == "5" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "7" and cardRank4DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "6" and cardRank3DAO == "8" and cardRank4DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "8" and cardRank4DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "6" and cardRank4DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "6" and cardRank4DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "7" and cardRank4DAO == "6" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "8" and cardRank4DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "7" and cardRank3DAO == "9" and cardRank4DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "9" and cardRank4DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "7" and cardRank4DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "7" and cardRank4DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "8" and cardRank4DAO == "7" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "9" and cardRank4DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "8" and cardRank3DAO == "10" and cardRank4DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "10" and cardRank4DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "8" and cardRank4DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank3DAO == "8" and cardRank4DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank3DAO == "9" and cardRank4DAO == "8" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "10" and cardRank4DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "9" and cardRank3DAO == "Jack" and cardRank4DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank3DAO == "Jack" and cardRank4DAO == "9" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "10" and cardRank3DAO == "9" and cardRank4DAO == "Jack" then
            if player3213AmountTextDAO:GetText() == "21+3 Side Bet: N/A" then
                SendChatMessage("{skull} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) but didn't place a side bet - unlucky!", "RAID")
            else
                player3StraightWinDAO()
                SendChatMessage("{star} Player 3 hit a Straight (Payout is " .. straightPayoutDAO .. ":1) - congratulations!", "RAID")
            end
        elseif cardRank1DAO == "Jack" and cardRank3DAO == "9" and cardRank4DAO == "10" then
            if player3213AmountTextDAO:GetText() == "21